<script src="../../static/js/jquery-2.2.1.min.js" th:src="@{js/jquery-2.2.1.min.js}"></script>
<!--<link href="../../static/css/jeDate-test.css" rel="stylesheet" th:href="@{/css/jeDate-test.css}"/>-->
<!--<link href="../../static/css/jedate.css" rel="stylesheet" th:href="@{/css/jedate.css}"/>-->
<!--<script src="../../static/js/jquery.jedate.js" th:src="@{/js/jquery.jedate.js}"></script>-->
<!--<script src="../../static/js/jedate-test.js" th:src="@{/js/jedate-test.js}"></script>-->
<link href="../../static/css/laydate.css" rel="stylesheet" th:href="@{css/laydate.css}"/>
<script src="../../static/js/laydate.js" th:src="@{js/laydate.js}"></script>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <title>统计分析</title>
    <script src="../../static/js/echarts.min.js" th:src="@{js/echarts.min.js}"></script>
    <script src="../../static/js/echarts-liquidfill.min.js" th:src="@{js/echarts-liquidfill.min.js}"></script>
    <script src="../../static/js/echarts-wordcloud.min.js" th:src="@{js/echarts-wordcloud.min.js}"></script>

    <script src="../../static/js/shine.js" th:src="@{js/shine.js}"></script>
</head>
<style>
    * {
        margin: 0;
        padding: 0;
        font-family: 微软雅黑;
    }
    .main {
        width: 100%;
        height: 100%;
        background: url("images/static_bg4.png");
        background-size: 100% 100%;
        position: absolute;
        top: 0;
        overflow: hidden;
    }
    .back{
        background: url("images/back.png");
        width: 90px;
        height: 24px;
        background-size: 100% 100%;
        position: absolute;
        right: 16%;
        top: 1.3%;
    }
    .top {
        width: 100%;
        height: 8%;
        /*border: 1px solid red;*/
    }
    .left {
        width: 30%;
        height: 92%;
        /*border: 1px solid red;*/
        float: left;
    }
    #nlzb {
        padding-left: 3%;
        width: 100%;
        height: 40.5%;
        margin-top:7%;
        /*border: 1px solid green;*/
    }
    #null {
        /*width: 110%;*/
        /*height: 31%;*/
        /*border: 1px solid green;*/
        margin-top: 2%;
        font-weight: bolder;
    }
    #xbzb {
        width: 100%;
        height: 30%;
        /*border: 1px solid green;*/
        margin-top: 14.2%;
    }
    .text_title {
        color: #00ffff;
    }
    .center {
        width: 40%;
        height: 92%;
        /*border: 1px solid green;*/
        float: left;
    }
    .list {
        width: 90%;
        height: 43%;
        /*border: 1px solid red;*/
        margin: 10% auto;
        padding: 10px;
        color: #00ffff;
        font-size: 0.9vw;
    }
    .list .text_title {
        width: 10%;
        height: 10%;
        float: left;
        margin-left: 2%;
        margin-top: 1%;
    }
    .list .text_title2 {
        width: 17%;
        height: 10%;
        float: left;
        margin-top: 1%;
    }
    .list .text_title3 {
        width: 65%;
        height: 10%;
        float: left;
        margin-top: 1%;
    }
    #map {
        width: 100%;
        height: 38%;
        /*border: 1px solid red;*/
    }
    .right {
        width: 29%;
        height: 92%;
        /*border: 1px solid red;*/
        float: left;
    }
    #kllfx {
        width: 100%;
        height: 45%;
        /*border: 1px solid green;*/
        margin-top: 1%;
    }
    #klltj {
        width: 100%;
        height: 45%;
        margin-top: 12%;
    }
    .ultext{
       clear: both;
        list-style: none;
    }
    .ultext li{
        float: left;
        line-height: 30px;
    }
    .li1{
        width: 10%;
        height: 10%;
        margin-left: 2%;
        margin-top: 1%;
    }
    .li2{
        width: 17%;
        height: 10%;
        margin-top: 1%;
    }
    .li3{
        width: 65%;
        height: 10%;
        margin-top: 1%;
    }
    .list div{
        font-size: 0.9vw;
    }
    .ultext{
        width: 100%;
        height: 10%;
    }


    .active{
        background: #0186f7;
        color: #ffffff;
        border-radius: 5px;
    }
    #appraise{
        height: 122%;
    }
    .datetab{
        list-style: none;
        width: 100%;
        height: 7.2%;
        margin-top:4%;
    }
    .datetab li{
        width: 17%;
        height: 100%;
        float: left;
        /*border: 1px solid red;*/
        margin-left: 2.8%;
    }
    .circle{
        width: 100%;
        height: 44.3%;
        /*border: 1px solid red;*/
    }
    .slzs{
        text-align: center;
        background: url(images/circle-center01.png) no-repeat;
        width: 60%;
        height: 86%;
        background-size: 100%;
        float: left;
        margin-top: 5%;
        position: relative;
        margin-left: 20%;
    }
    .circle01{
        position: absolute;
        top: -11%;
        left: 16.5%;
        background: url(images/circle01.png) no-repeat;
        width: 66%;
        height: 92.5%;
        background-size: 100%;
        animation: myframes01 5s linear infinite;
    }
    @keyframes myframes01{
        from{transform: rotate(0deg)}
        to{transform: rotate(360deg);}
    }
    .klzl-title{
        margin-top: 13%;
        color: #fff;
        font-size: 1.5rem;
    }
    #test6{
        border: 1px solid #2590fb;
        position: absolute;
        top: 1.8%;
        left: 15.7%;
        width: 10.5%;
        height: 3%;
        background: #031756;
        color: #b2cfec;
        padding-left:0.8%;
    }
    .query{
        position: absolute;
        top: 1.8%;
        left: 26.7%;
        width: 3%;
        height: 3%;
        background: #031756;
        color: #fff;
        border: 1px solid #2590fb;
        border-radius: 3px;
    }
</style>
<body>
<div class="main">
    <div class="top">
        <input type="hidden" class="jeinput" id="sdate" name="cdate" value="0"
               style="display:none"/>
        <input type="hidden" class="jeinput" id="udate" name="udate" value="0"
               style="display:none"/>
        <input type="text" class="layui-input" id="test6" placeholder=" - " lay-key="7">
        <button class="query" type="button" onclick="findByTime()">查询</button>
        <a class="back" href='index.html'></a>
    </div>
    <div class="left">
        <div id="main" style="width: 98%;height: 60%;margin-left: 1%"></div>

        <div id="xbzb">
            <div style="float: left;width: 50%;height: 100%">
                <div id="nan" style="width: 100%;height: 85%;"></div>
                <div style="width: 100%;text-align: center;color: #ffffff;">男</div>
            </div>
            <div style="float: left;width: 50%;height: 100%">
                <div id="nv" style="width: 100%;height: 85%;"></div>
                <div style="width: 100%;text-align: center;color: #ffffff;">女</div>
            </div>

        </div>
    </div>
    <div class="center">
        <ul class="datetab">
            <li onclick="set(1)"></li>
            <li onclick="set(2)"></li>
            <li onclick="set(3)"></li>
            <li onclick="set(4)"></li>
            <li onclick="set(0)"></li>
        </ul>
        <div class="circle">
            <div class="slzs">
                <div class="circle01"></div>
                <div class="klzl-title">客流总量</div>
                <div id="null">
                <div style="color: #22d1e4;font-size: 1.2vw">423</div>
                </div>
            </div>
        </div>
        <div id="nlzb"></div>
    </div>
    <div class="right">
        <div id="kllfx"></div>
        <div id="klltj"></div>
        <div id="cyzss"></div>
    </div>
</div>
<script src="../../static/js/china.js" th:src="@{js/china.js}"></script>

<script type="text/javascript" th:inline="javascript">
    laydate.render({
        elem: '#test6'
        ,range: true,
        done: function (value, date, endDate) {
            if (value === "") {
                $("#sdate").val("0");
                $("#udate").val("0");
            }
        },
        change: function (value, date, endDate) {
            $("#sdate").val(date['year'] + "-" + date['month'] + "-" + date['date'] + " " + date['hours'] + ":" + date['minutes'] + ":" + date['seconds']);
            $("#udate").val(endDate['year'] + "-" + endDate['month'] + "-" + endDate['date'] + " 23:59:59");
        }
    });
    /*<![CDATA[*/
    document.onkeydown=function(event){
                    var e = event || window.event || arguments.callee.caller.arguments[0];
                    if(e && e.keyCode==122){
                                   $(".circle01").css({"top":"-10%","height":"81%"});
                          }

                };
    var time="0";
    $(function () {

        $(".list ul:not(first)").css("margin-top","1.3%")
    })
    //评价展示1
//    $.get("/statistics/findAppraiseList/"+time, function (request) {
//        console.log(request);
//        var html ="";
//        $.each(request,function (index,item) {
//            html +="<ul class='ultext'> <li class='li1'> "+item.name+"</li> <li class='li2'>"+item.star+"</li> <li class='li3'>"+item.content+"</li> </ul>";
//        })
//        $("#appraise").empty();
//        $("#appraise").append(html);
//    });

    $(function () {
        setInterval(function () {
            var sdate=$("#sdate").val();
            var udate=$("#udate").val();
            //评价展示
//            $.get("/statistics/findAppraiseList/"+time, function (request) {
//                console.log(request);
//                var html ="";
//                $.each(request,function (index,item) {
//                    html +="<ul class='ultext'> <li class='li1'> "+item.name+"</li> <li class='li2'>"+item.star+"</li> <li class='li3'>"+item.content+"</li> </ul>";
//                })
//                $("#appraise").empty();
//                $("#appraise").append(html);
//            });
//            $('html').load(/*[[@{/screen}]]*/"./static/static.html")
            //当前客流总量
            $.get("statistics/current/" + time + "/" + sdate + "/" + udate, function (request) {
                $("#null").empty()
                $("#null").append("<div style=\"color: #22d1e4;font-size: 2vw\">" + request + "</div>")
            });
            //年龄占比
            $.get("statistics/age/" + time + "/" + sdate + "/" + udate, function (request) {
                var sum = 0;
                for(var i=0;i<request.length;i++){
                    sum += request[i];
                }
                var myChart = echarts.init(document.getElementById('nlzb'));
                option = {
                    xAxis: {
                        data: ['0~10', '10~20', '20~30', '30~40', '40~50', '50~60', '60~70', '70~80', '80~90', '90~100'],
                        axisLine: {
                            lineStyle: {
                                color: '#0177d4'
                            }
                        },
                        axisLabel: {
                            color: '#fff',
                            fontSize: 14
                        }
                    },
                    yAxis: {
                        name: "（人）",
                        nameTextStyle: {
                            color: '#fff',
                            fontSize: 16
                        },
                        axisLine: {
                            lineStyle: {
                                color: '#0177d4'
                            }
                        },
                        axisLabel: {
                            color: '#fff',
                            fontSize: 16
                        },
                        splitLine: {
                            show: false,
                            lineStyle: {
                                color: '#0177d4'
                            }
                        },
                        interval: Math.round(sum/10),
                        max: sum
                    },
                    series: [{
                        type: 'bar',
                        barWidth: 18,
                        itemStyle: {
                            normal: {
                                color: new echarts.graphic.LinearGradient(0, 0, 0, 1, [{
                                    offset: 0,
                                    color: '#00b0ff'
                                }, {
                                    offset: 0.8,
                                    color: '#7052f4'
                                }], false)
                            }
                        },
                        data: request
                    }]
                };
                myChart.setOption(option);
            });
            //性别占比
            $.get("statistics/sex/" + time + "/" + sdate + "/" + udate, function (request) {
                var count = request.manCount+request.womanCount;
                var woman = request.womanCount/count;
                var man = request.manCount/count;
                var womanCount = [woman,0.5,0.4,0.3]
                var manCount = [man,0.5,0.4,0.3]

                var myChart = echarts.init(document.getElementById('nan'));
                option = {
                    series: [{
                        type: 'liquidFill',
                        data: manCount,
                        radius: '80%'
                    }]
                };
                myChart.setOption(option);
                var myChart = echarts.init(document.getElementById('nv'));
                option = {
                    series: [{
                        type: 'liquidFill',
                        data: womanCount,
                        radius: '80%'

                    }]
                };
                myChart.setOption(option);
            })
            //各省参观人数
            $.get("statistics/province/" + time + "/" + sdate + "/" + udate, function (request) {
                var province = [];
                $(request).each(function (x, y) {
                    province.push({name:y.regionName,value:y.count})
                })

                var myChart = echarts.init(document.getElementById('main'));

                var data = [
                    {name: '海门', value: 9},
                    {name: '鄂尔多斯', value: 12},
                    {name: '招远', value: 12},
                    {name: '舟山', value: 12},
                    {name: '齐齐哈尔', value: 14},
                    {name: '盐城', value: 15},
                    {name: '赤峰', value: 16},
                    {name: '青岛', value: 18},
                    {name: '乳山', value: 18},
                    {name: '金昌', value: 19},
                    {name: '泉州', value: 21},
                    {name: '南通', value: 23},
                    {name: '拉萨', value: 24},
                    {name: '云浮', value: 24},
                    {name: '上海', value: 25},
                    {name: '攀枝花', value: 25},
                    {name: '承德', value: 25},
                    {name: '汕尾', value: 26},
                    {name: '丹东', value: 27},
                    {name: '瓦房店', value: 30},
                    {name: '延安', value: 38},
                    {name: '咸阳', value: 43},
                    {name: '南昌', value: 54},
                    {name: '柳州', value: 54},
                    {name: '三亚', value: 54},
                    {name: '泸州', value: 57},
                    {name: '克拉玛依', value: 72}
                ];

                var geoCoordMap = {
                    '海门': [121.15, 31.89],
                    '鄂尔多斯': [109.781327, 39.608266],
                    '招远': [120.38, 37.35],
                    '舟山': [122.207216, 29.985295],
                    '齐齐哈尔': [123.97, 47.33],
                    '盐城': [120.13, 33.38],
                    '赤峰': [118.87, 42.28],
                    '青岛': [120.33, 36.07],
                    '乳山': [121.52, 36.89],
                    '金昌': [102.188043, 38.520089],
                    '泉州': [118.58, 24.93],
                    '莱西': [120.53, 36.86],
                    '日照': [119.46, 35.42],
                    '胶南': [119.97, 35.88],
                    '南通': [121.05, 32.08],
                    '拉萨': [91.11, 29.97],
                    '云浮': [112.02, 22.93],
                    '梅州': [116.1, 24.55],
                    '文登': [122.05, 37.2],
                    '上海': [121.48, 31.22],
                    '攀枝花': [101.718637, 26.582347],
                    '威海': [122.1, 37.5],
                    '承德': [117.93, 40.97],
                    '厦门': [118.1, 24.46],
                    '汕尾': [115.375279, 22.786211],
                    '潮州': [116.63, 23.68],
                    '丹东': [124.37, 40.13],
                    '太仓': [121.1, 31.45],
                    '曲靖': [103.79, 25.51],
                    '烟台': [121.39, 37.52],
                    '福州': [119.3, 26.08],
                    '瓦房店': [121.979603, 39.627114],
                    '即墨': [120.45, 36.38],
                    '抚顺': [123.97, 41.97],
                    '玉溪': [102.52, 24.35],
                    '张家口': [114.87, 40.82],
                    '阳泉': [113.57, 37.85],
                    '莱州': [119.942327, 37.177017],
                    '湖州': [120.1, 30.86],
                    '汕头': [116.69, 23.39],
                    '昆山': [120.95, 31.39],
                    '宁波': [121.56, 29.86],
                    '湛江': [110.359377, 21.270708],
                    '揭阳': [116.35, 23.55],
                    '荣成': [122.41, 37.16],
                    '连云港': [119.16, 34.59],
                    '葫芦岛': [120.836932, 40.711052],
                    '常熟': [120.74, 31.64],
                    '东莞': [113.75, 23.04],
                    '河源': [114.68, 23.73],
                    '淮安': [119.15, 33.5],
                    '泰州': [119.9, 32.49],
                    '南宁': [108.33, 22.84],
                    '营口': [122.18, 40.65],
                    '惠州': [114.4, 23.09],
                    '江阴': [120.26, 31.91],
                    '蓬莱': [120.75, 37.8],
                    '韶关': [113.62, 24.84],
                    '嘉峪关': [98.289152, 39.77313],
                    '广州': [113.23, 23.16],
                    '延安': [109.47, 36.6],
                    '太原': [112.53, 37.87],
                    '清远': [113.01, 23.7],
                    '中山': [113.38, 22.52],
                    '昆明': [102.73, 25.04],
                    '寿光': [118.73, 36.86],
                    '盘锦': [122.070714, 41.119997],
                    '长治': [113.08, 36.18],
                    '深圳': [114.07, 22.62],
                    '珠海': [113.52, 22.3],
                    '宿迁': [118.3, 33.96],
                    '咸阳': [108.72, 34.36],
                    '铜川': [109.11, 35.09],
                    '平度': [119.97, 36.77],
                    '佛山': [113.11, 23.05],
                    '海口': [110.35, 20.02],
                    '江门': [113.06, 22.61],
                    '章丘': [117.53, 36.72],
                    '肇庆': [112.44, 23.05],
                    '大连': [121.62, 38.92],
                    '临汾': [111.5, 36.08],
                    '吴江': [120.63, 31.16],
                    '石嘴山': [106.39, 39.04],
                    '沈阳': [123.38, 41.8],
                    '苏州': [120.62, 31.32],
                    '茂名': [110.88, 21.68],
                    '嘉兴': [120.76, 30.77],
                    '长春': [125.35, 43.88],
                    '胶州': [120.03336, 36.264622],
                    '银川': [106.27, 38.47],
                    '张家港': [120.555821, 31.875428],
                    '三门峡': [111.19, 34.76],
                    '锦州': [121.15, 41.13],
                    '南昌': [115.89, 28.68],
                    '柳州': [109.4, 24.33],
                    '三亚': [109.511909, 18.252847],
                    '自贡': [104.778442, 29.33903],
                    '吉林': [126.57, 43.87],
                    '阳江': [111.95, 21.85],
                    '泸州': [105.39, 28.91],
                    '西宁': [101.74, 36.56],
                    '宜宾': [104.56, 29.77],
                    '呼和浩特': [111.65, 40.82],
                    '成都': [104.06, 30.67],
                    '大同': [113.3, 40.12],
                    '镇江': [119.44, 32.2],
                    '桂林': [110.28, 25.29],
                    '张家界': [110.479191, 29.117096],
                    '宜兴': [119.82, 31.36],
                    '北海': [109.12, 21.49],
                    '西安': [108.95, 34.27],
                    '金坛': [119.56, 31.74],
                    '东营': [118.49, 37.46],
                    '牡丹江': [129.58, 44.6],
                    '遵义': [106.9, 27.7],
                    '绍兴': [120.58, 30.01],
                    '扬州': [119.42, 32.39],
                    '常州': [119.95, 31.79],
                    '潍坊': [119.1, 36.62],
                    '重庆': [106.54, 29.59],
                    '台州': [121.420757, 28.656386],
                    '南京': [118.78, 32.04],
                    '滨州': [118.03, 37.36],
                    '贵阳': [106.71, 26.57],
                    '无锡': [120.29, 31.59],
                    '本溪': [123.73, 41.3],
                    '克拉玛依': [84.77, 45.59],
                    '渭南': [109.5, 34.52],
                    '马鞍山': [118.48, 31.56],
                    '宝鸡': [107.15, 34.38],
                    '焦作': [113.21, 35.24],
                    '句容': [119.16, 31.95],
                    '北京': [116.46, 39.92],
                    '徐州': [117.2, 34.26],
                    '衡水': [115.72, 37.72],
                    '包头': [110, 40.58],
                    '绵阳': [104.73, 31.48],
                    '乌鲁木齐': [87.68, 43.77],
                    '枣庄': [117.57, 34.86],
                    '杭州': [120.19, 30.26],
                    '淄博': [118.05, 36.78],
                    '鞍山': [122.85, 41.12],
                    '溧阳': [119.48, 31.43],
                    '库尔勒': [86.06, 41.68],
                    '安阳': [114.35, 36.1],
                    '开封': [114.35, 34.79],
                    '济南': [117, 36.65],
                    '德阳': [104.37, 31.13],
                    '温州': [120.65, 28.01],
                    '九江': [115.97, 29.71],
                    '邯郸': [114.47, 36.6],
                    '临安': [119.72, 30.23],
                    '兰州': [103.73, 36.03],
                    '沧州': [116.83, 38.33],
                    '临沂': [118.35, 35.05],
                    '南充': [106.110698, 30.837793],
                    '天津': [117.2, 39.13],
                    '富阳': [119.95, 30.07],
                    '泰安': [117.13, 36.18],
                    '诸暨': [120.23, 29.71],
                    '郑州': [113.65, 34.76],
                    '哈尔滨': [126.63, 45.75],
                    '聊城': [115.97, 36.45],
                    '芜湖': [118.38, 31.33],
                    '唐山': [118.02, 39.63],
                    '平顶山': [113.29, 33.75],
                    '邢台': [114.48, 37.05],
                    '德州': [116.29, 37.45],
                    '济宁': [116.59, 35.38],
                    '荆州': [112.239741, 30.335165],
                    '宜昌': [111.3, 30.7],
                    '义乌': [120.06, 29.32],
                    '丽水': [119.92, 28.45],
                    '洛阳': [112.44, 34.7],
                    '秦皇岛': [119.57, 39.95],
                    '株洲': [113.16, 27.83],
                    '石家庄': [114.48, 38.03],
                    '莱芜': [117.67, 36.19],
                    '常德': [111.69, 29.05],
                    '保定': [115.48, 38.85],
                    '湘潭': [112.91, 27.87],
                    '金华': [119.64, 29.12],
                    '岳阳': [113.09, 29.37],
                    '长沙': [113, 28.21],
                    '衢州': [118.88, 28.97],
                    '廊坊': [116.7, 39.53],
                    '菏泽': [115.480656, 35.23375],
                    '合肥': [117.27, 31.86],
                    '武汉': [114.31, 30.52],
                    '大庆': [125.03, 46.58]
                };

                function convertData(data) {
                    var res = [];
                    for (var i = 0; i < data.length; i++) {
                        var geoCoord = geoCoordMap[data[i].name];
                        if (geoCoord) {
                            res.push({
                                name: data[i].name,
                                value: geoCoord.concat(data[i].value)
                            });
                        }
                    }
                    return res;
                };

                function randomValue() {
                    return Math.round(Math.random() * 1000);
                }


                option = {
                    tooltip: {},
                    visualMap: {
                        min: 0,
                        max: 1500,
                        left: 'left',
                        top: 'bottom',
                        text: ['高', '低'],
                        seriesIndex: [1],
                        inRange: {
                            color: ['#e0ffff', '#006edd']
                        },
                        textStyle: {
                            color: '#006edd'
                        },
                        calculable: true
                    },
                    geo: {
                        map: 'china',
                        roam: true,
                        label: {
                            normal: {
                                show: false,
                                textStyle: {
                                    color: 'rgba(0,0,0,0.4)'
                                }
                            }
                        },
                        itemStyle: {
                            normal: {
                                borderColor: 'rgba(0, 0, 0, 0.2)'
                            },
                            emphasis: {
                                areaColor: null,
                                shadowOffsetX: 0,
                                shadowOffsetY: 0,
                                shadowBlur: 20,
                                borderWidth: 0,
                                shadowColor: 'rgba(0, 0, 0, 0.5)'
                            }
                        }
                    },
                    series: [
                        {
                            type: 'scatter',
                            coordinateSystem: 'geo',
                            data: convertData(data),
                            symbolSize: 0,

                            symbol: 'image://imgs/pe.png',
//                symbol: '23',
//

                            symbolRotate: 25,
                            label: {
                                normal: {
                                    formatter: '{b}',
                                    position: 'right',
                                    show: false
                                },
                                emphasis: {
                                    show: true
                                }
                            },
                            itemStyle: {
                                normal: {
//                        color: '#F06C00'
                                }
                            }
                        },
                        {
                            name: '',
                            type: 'map',
                            geoIndex: 0,
                            // tooltip: {show: false},
                            data:province

                        }
                    ]
                };
                myChart.setOption(option);
            })
            //客流量分析
            $.get("statistics/futureOneMonth/" + time + "/" + sdate + "/" + udate, function (request) {
                var myChart = echarts.init(document.getElementById('kllfx'));
                option = {
                    tooltip: {
                        trigger: 'axis',
                        axisPointer: {
                            lineStyle: {
                                color: '#57617B'
                            }
                        }
                    },
                    legend: {
                        icon: 'rect',
                        itemWidth: 14,
                        itemHeight: 5,
                        itemGap: 13,
                        data: ['增长数'],
                        right: '4%',
                        textStyle: {
                            fontSize: 12,
                            color: '#F1F1F3'
                        }
                    },
                    grid: {
                        left: '3%',
                        right: '4%',
                        bottom: '3%',
                        containLabel: true
                    },
                    xAxis: [{
                        type: 'category',
                        boundaryGap: false,
                        axisLine: {
                            lineStyle: {
                                color: '#00c7ff'
                            }
                        },
                        data: ['未来第一月', '未来第二月', '未来第三月', '未来第四月', '未来第五月', '未来第六月']
                    }],
                    yAxis: [{
                        type: 'value',
                        axisTick: {
                            show: false
                        },
                        axisLine: {
                            lineStyle: {
                                color: '#00c7ff'
                            }
                        },
                        axisLabel: {
                            margin: 10,
                            textStyle: {
                                fontSize: 14
                            }
                        },
                        splitLine: {
                            show: false
                        }
                    }],
                    series: [{
                        name: '增长数',
                        type: 'line',
                        smooth: true,
                        symbol: 'circle',
                        symbolSize: 5,
                        showSymbol: false,
                        lineStyle: {
                            normal: {
                                width: 1
                            }
                        },
                        areaStyle: {
                            normal: {
                                color: new echarts.graphic.LinearGradient(0, 0, 0, 1, [{
                                    offset: 0,
                                    color: '#5ff6e9'
                                }, {
                                    offset: 0.8,
                                    color: '#7370fd'
                                }], false),
                                shadowColor: 'rgba(0, 0, 0, 0.1)',
                                shadowBlur: 10
                            }
                        },
                        itemStyle: {
                            normal: {
                                color: 'rgb(137,189,27)',
                                borderColor: 'rgba(137,189,2,0.27)',
                                borderWidth: 12

                            }
                        },
                        data: request
                    }]
                };
                myChart.setOption(option);
            })
            //词云展示
            var myChart = echarts.init(document.getElementById('cyzss'));
            option = {
                title: {
                    text: ''
                },
                tooltip: {},
                animationDurationUpdate: 1500,
                animationEasingUpdate: 'quinticInOut',
                color: ['#83e0ff', '#45f5ce', '#b158ff'],
                legend: {
                    show: true,
                    data: [
                        {name: '', textStyle: {color: '#fff'}},
                        {name: '', textStyle: {color: '#fff'}},
                        {name: '', textStyle: {color: '#fff'}}
                    ]
                },
                series: [
                    {
                        type: 'graph',
                        layout: 'force',
                        force: {
                            repulsion: 1000,
                            edgeLength: 50
                        },
                        symbolSize: 50,
                        roam: true,
                        label: {
                            normal: {
                                show: true
                            }
                        },
                        edgeSymbolSize: [4, 10],
                        edgeLabel: {
                            normal: {
                                show: true,
                                textStyle: {
                                    fontSize: 13
                                },
                                formatter: "{c}"
                            }
                        },

                        data: [
                            {
                                name: '说明',

                                symbolSize: 100,
                                draggable: true,
                                category: 1,
                                itemStyle: {
                                    normal: {
                                        borderColor: '#04f2a7',
                                        borderWidth: 6,
                                        shadowBlur: 20,
                                        shadowColor: '#04f2a7',
                                        color: '#001c43',
                                    }
                                }
                            },
                            {
                                name: '刀',
                                symbolSize: 70,
                                itemStyle: {
                                    normal: {
                                        borderColor: '#04f2a7',
                                        borderWidth: 4,
                                        shadowBlur: 10,
                                        shadowColor: '#04f2a7',
                                        color: '#001c43',
                                    }
                                },
                                category: 1,

                            },
                            {
                                name: '指纹',
                                symbolSize: 70,
                                category: 1,
                                itemStyle: {
                                    normal: {
                                        borderColor: '#04f2a7',
                                        borderWidth: 4,
                                        shadowBlur: 10,
                                        shadowColor: '#04f2a7',
                                        color: '#001c43',
                                    }
                                },

                            },
                            {
                                name: '张三',
                                symbolSize: 70,
                                category: 0,
                                itemStyle: {
                                    normal: {
                                        borderColor: '#82dffe',
                                        borderWidth: 4,
                                        shadowBlur: 10,
                                        shadowColor: '#04f2a7',
                                        color: '#001c43',
                                    }
                                },

                            },
                            {
                                name: '李四',
                                symbolSize: 70,
                                category: 0,
                                itemStyle: {
                                    normal: {
                                        borderColor: '#82dffe',
                                        borderWidth: 4,
                                        shadowBlur: 10,
                                        shadowColor: '#04f2a7',
                                        color: '#001c43',
                                    }
                                },

                            },
                            {
                                name: '张三2',
                                category: 0,
                                itemStyle: {
                                    normal: {
                                        borderColor: '#82dffe',
                                        borderWidth: 4,
                                        shadowBlur: 10,
                                        shadowColor: '#04f2a7',
                                        color: '#001c43',
                                    }
                                },

                            },
                            {
                                name: '无名尸',
                                category: 2,
                                itemStyle: {
                                    normal: {
                                        borderColor: '#b457ff',
                                        borderWidth: 4,
                                        shadowBlur: 10,
                                        shadowColor: '#b457ff',
                                        color: '#001c43'
                                    }
                                },

                            },
                            {
                                name: '赖子',
                                itemStyle: {
                                    normal: {
                                        borderColor: '#82dffe',
                                        borderWidth: 4,
                                        shadowBlur: 10,
                                        shadowColor: '#04f2a7',
                                        color: '#001c43'

                                    }
                                },
                                category: 0,

                            },
                            {
                                name: '王五',
                                itemStyle: {
                                    normal: {
                                        borderColor: '#82dffe',
                                        borderWidth: 4,
                                        shadowBlur: 10,
                                        shadowColor: '#04f2a7',
                                        color: '#001c43'
                                    }
                                },
                                category: 0,

                            },
                            {
                                name: '刘大',
                                category: 0,
                                itemStyle: {
                                    normal: {
                                        borderColor: '#82dffe',
                                        borderWidth: 4,
                                        shadowBlur: 10,
                                        shadowColor: '#04f2a7',
                                        color: '#001c43'
                                    }
                                },

                            }],
                        links: [
                            {
                                source: '说明',
                                target: '刀',
                                value: '',
                                lineStyle: {
                                    normal: {
                                        color: {
                                            type: 'linear',
                                            x: 0,
                                            y: 0,
                                            x2: 0,
                                            y2: 1,
                                            colorStops: [{
                                                offset: 0, color: '#e0f55a' // 0% 处的颜色
                                            }, {
                                                offset: 1, color: '#639564' // 100% 处的颜色
                                            }],
                                            globalCoord: false // 缺省为 false
                                        }
                                    }
                                }

                            },
                            {
                                source: '说明',
                                target: '指纹',
                                value: '',
                                lineStyle: {
                                    normal: {
                                        color: {
                                            type: 'linear',
                                            x: 0,
                                            y: 0,
                                            x2: 0,
                                            y2: 1,
                                            colorStops: [{
                                                offset: 0, color: '#eda553' // 0% 处的颜色
                                            }, {
                                                offset: 1, color: '#7c785b' // 100% 处的颜色
                                            }],
                                            globalCoord: false // 缺省为 false
                                        }
                                    }
                                },
                            },
                            {
                                source: '说明',
                                target: '张三',
                                value: '',
                                lineStyle: {
                                    normal: {
                                        color: {
                                            type: 'linear',
                                            x: 0,
                                            y: 0,
                                            x2: 0,
                                            y2: 1,
                                            colorStops: [{
                                                offset: 0, color: '#eda553' // 0% 处的颜色
                                            }, {
                                                offset: 1, color: '#7c785b' // 100% 处的颜色
                                            }],
                                            globalCoord: false // 缺省为 false
                                        }
                                    }
                                },
                            },
                            {
                                source: '说明',
                                target: '李四',
                                value: '',
                                lineStyle: {
                                    normal: {
                                        color: {
                                            type: 'linear',
                                            x: 0,
                                            y: 0,
                                            x2: 0,
                                            y2: 1,
                                            colorStops: [{
                                                offset: 0, color: '#e0f55a' // 0% 处的颜色
                                            }, {
                                                offset: 1, color: '#639564' // 100% 处的颜色
                                            }],
                                            globalCoord: false // 缺省为 false
                                        }
                                    }
                                }
                            },
                            {
                                source: '说明',
                                target: '张三'
                            },
                            {
                                source: '刀',
                                target: '张三2',
                                value: '',
                                lineStyle: {
                                    normal: {
                                        color: {
                                            type: 'linear',
                                            x: 0,
                                            y: 0,
                                            x2: 0,
                                            y2: 1,
                                            colorStops: [{
                                                offset: 0, color: '#e0f55a' // 0% 处的颜色
                                            }, {
                                                offset: 1, color: '#639564' // 100% 处的颜色
                                            }],
                                            globalCoord: false // 缺省为 false
                                        }
                                    }
                                }
                            },
                            {
                                source: '刀',
                                target: '无名尸', value: '',
                                lineStyle: {
                                    normal: {
                                        color: {
                                            type: 'linear',
                                            x: 0,
                                            y: 0,
                                            x2: 0,
                                            y2: 1,
                                            colorStops: [{
                                                offset: 0, color: '#e0f55a' // 0% 处的颜色
                                            }, {
                                                offset: 1, color: '#639564' // 100% 处的颜色
                                            }],
                                            globalCoord: false // 缺省为 false
                                        }
                                    }
                                }

                            },
                            {
                                source: '李四',
                                target: '赖子',
                                value: '',
                                lineStyle: {
                                    normal: {
                                        color: {
                                            type: 'linear',
                                            x: 0,
                                            y: 0,
                                            x2: 0,
                                            y2: 1,
                                            colorStops: [{
                                                offset: 0, color: '#e0f55a' // 0% 处的颜色
                                            }, {
                                                offset: 1, color: '#639564' // 100% 处的颜色
                                            }],
                                            globalCoord: false // 缺省为 false
                                        }
                                    }
                                }
                            },
                            {
                                source: '李四',
                                target: '王五',
                                value: '',
                                lineStyle: {
                                    normal: {
                                        color: {
                                            type: 'linear',
                                            x: 0,
                                            y: 0,
                                            x2: 0,
                                            y2: 1,
                                            colorStops: [{
                                                offset: 0, color: '#df6f30' // 0% 处的颜色
                                            }, {
                                                offset: 1, color: '#915034' // 100% 处的颜色
                                            }],
                                            globalCoord: false // 缺省为 false
                                        }
                                    }
                                },
                            },
                            {
                                source: '王五',
                                target: '刘大',
                                value: '',
                                lineStyle: {
                                    normal: {
                                        color: {
                                            type: 'linear',
                                            x: 0,
                                            y: 0,
                                            x2: 0,
                                            y2: 1,
                                            colorStops: [{
                                                offset: 0, color: '#eda553' // 0% 处的颜色
                                            }, {
                                                offset: 1, color: '#7c785b' // 100% 处的颜色
                                            }],
                                            globalCoord: false // 缺省为 false
                                        }
                                    }
                                },
                            }
                        ],
                        lineStyle: {
                            normal: {
                                opacity: 0.9,
                                width: 5,
                                curveness: 0
                            }
                        },
                        categories: [
                            {name: '人'},
                            {name: '物证'},
                            {name: '不明物体'}
                        ]
                    }
                ]
            }
            myChart.setOption(option);
            //客流量统计
            $.get("statistics/passengerStatistics/" + time + "/" + sdate + "/" + udate, function (request) {
                var myChart = echarts.init(document.getElementById('klltj'));
                option = {
                    tooltip: {
                        trigger: 'axis',
                        axisPointer: {
                            type: 'shadow'
                        }
                    },
                    legend: {
                        data: ['男性', '女性'],
                        align: 'right',
                        right: 10,
                        textStyle: {
                            color: "#fff"
                        },
                        itemWidth: 10,
                        itemHeight: 10,
                        itemGap: 35
                    },
                    grid: {
                        left: '3%',
                        right: '4%',
                        bottom: '3%',
                        containLabel: true
                    },
                    xAxis: [{
                        type: 'category',
                        data: request.province,
                        axisLine: {
                            show: true,
                            lineStyle: {
                                color: "#063374",
                                width: 1,
                                type: "solid"
                            }
                        },
                        axisTick: {
                            show: false,
                        },
                        axisLabel: {
                            show: true,
                            textStyle: {
                                color: "#00c7ff",
                            }
                        },
                    }],
                    yAxis: [{
                        type: 'value',
                        axisLabel: {
                            formatter: '{value}'
                        },
                        axisTick: {
                            show: false,
                        },
                        axisLine: {
                            show: false,
                            lineStyle: {
                                color: "#00c7ff",
                                width: 1,
                                type: "solid"
                            },
                        },
                        splitLine: {
                            lineStyle: {
                                color: "#063374",
                            }
                        }
                    }],
                    series: [{
                        name: '男性',
                        type: 'bar',
                        data: request.man,
                        barWidth: 10, //柱子宽度
                        barGap: 1, //柱子之间间距
                        itemStyle: {
                            normal: {
                                color: new echarts.graphic.LinearGradient(0, 0, 0, 1, [{
                                    offset: 0,
                                    color: '#008cff'
                                }, {
                                    offset: 1,
                                    color: '#005193'
                                }]),
                                opacity: 1,
                            }
                        }
                    }, {
                        name: '女性',
                        type: 'bar',
                        data: request.woman,
                        barWidth: 10,
                        barGap: 1,
                        itemStyle: {
                            normal: {
                                color: new echarts.graphic.LinearGradient(0, 0, 0, 1, [{
                                    offset: 0,
                                    color: '#00da9c'
                                }, {
                                    offset: 1,
                                    color: '#007a55'
                                }]),
                                opacity: 1,
                            }
                        }
                    }
                        /*, {
                         name: '完好率',
                         type: 'bar',
                         data: [47, 50, 72, 96, 86],
                         barWidth: 10,
                         barGap: 1,
                         itemStyle: {
                         normal: {
                         color: new echarts.graphic.LinearGradient(0, 0, 0, 1, [{
                         offset: 0,
                         color: '#c4e300'
                         }, {
                         offset: 1,
                         color: '#728400'
                         }]),
                         opacity: 1,
                         }
                         }
                         }*/]
                };
                myChart.setOption(option);
            });

        },5000);

    });
//    当前客流总量
    var sdate=$("#sdate").val();
    var udate=$("#udate").val();
    $.get("statistics/current/" + time + "/" + sdate + "/" + udate, function (request) {
        $("#null").empty()
        $("#null").append("<div style=\"color: #22d1e4;font-size: 2vw\">" + request + "</div>")
    });
    //年龄占比1
    $.get("statistics/age/" + time + "/" + sdate + "/" + udate, function (request) {
        var sum = 0;
        for(var i=0;i<request.length;i++){
            sum += request[i];
        }
        var myChart = echarts.init(document.getElementById('nlzb'));
        option = {
            xAxis: {
                data: ['0~10', '10~20', '20~30', '30~40', '40~50', '50~60', '60~70', '70~80', '80~90', '90~100'],
                axisLine: {
                    lineStyle: {
                        color: '#0177d4'
                    }
                },
                axisLabel: {
                    color: '#fff',
                    fontSize: 14
                }
            },
            yAxis: {
                name: "（人）",
                nameTextStyle: {
                    color: '#fff',
                    fontSize: 16
                },
                axisLine: {
                    lineStyle: {
                        color: '#0177d4'
                    }
                },
                axisLabel: {
                    color: '#fff',
                    fontSize: 16
                },
                splitLine: {
                    show: false,
                    lineStyle: {
                        color: '#0177d4'
                    }
                },
                interval: sum/10,
                max: sum
            },
            series: [{
                type: 'bar',
                barWidth: 18,
                itemStyle: {
                    normal: {
                        color: new echarts.graphic.LinearGradient(0, 0, 0, 1, [{
                            offset: 0,
                            color: '#00b0ff'
                        }, {
                            offset: 0.8,
                            color: '#7052f4'
                        }], false)
                    }
                },
                data: request
            }]
        };
        myChart.setOption(option);
    });
    //性别占比1
    $.get("statistics/sex/" + time + "/" + sdate + "/" + udate, function (request) {
        var count = request.manCount+request.womanCount;
        var woman = request.womanCount/count;
        var man = request.manCount/count;
        var womanCount = [woman,0.5,0.4,0.3]
        var manCount = [man,0.5,0.4,0.3]

    var myChart = echarts.init(document.getElementById('nan'));
    option = {
        series: [{
            type: 'liquidFill',
            data: manCount,
            radius: '80%'
        }]
    };
    myChart.setOption(option);
    var myChart = echarts.init(document.getElementById('nv'));
    option = {
        series: [{
            type: 'liquidFill',
            data: womanCount,
            radius: '80%'

        }]
    };
    myChart.setOption(option);
    })
    //各省参观人数1
    $.get("statistics/province/" + time + "/" + sdate + "/" + udate, function (request) {
        var province = [];
        $(request).each(function (x, y) {
            province.push({name:y.regionName,value:y.count})
        })

    var myChart = echarts.init(document.getElementById('main'));

    var data = [
        {name: '海门', value: 9},
        {name: '鄂尔多斯', value: 12},
        {name: '招远', value: 12},
        {name: '舟山', value: 12},
        {name: '齐齐哈尔', value: 14},
        {name: '盐城', value: 15},
        {name: '赤峰', value: 16},
        {name: '青岛', value: 18},
        {name: '乳山', value: 18},
        {name: '金昌', value: 19},
        {name: '泉州', value: 21},
        {name: '南通', value: 23},
        {name: '拉萨', value: 24},
        {name: '云浮', value: 24},
        {name: '上海', value: 25},
        {name: '攀枝花', value: 25},
        {name: '承德', value: 25},
        {name: '汕尾', value: 26},
        {name: '丹东', value: 27},
        {name: '瓦房店', value: 30},
        {name: '延安', value: 38},
        {name: '咸阳', value: 43},
        {name: '南昌', value: 54},
        {name: '柳州', value: 54},
        {name: '三亚', value: 54},
        {name: '泸州', value: 57},
        {name: '克拉玛依', value: 72}
    ];

    var geoCoordMap = {
        '海门': [121.15, 31.89],
        '鄂尔多斯': [109.781327, 39.608266],
        '招远': [120.38, 37.35],
        '舟山': [122.207216, 29.985295],
        '齐齐哈尔': [123.97, 47.33],
        '盐城': [120.13, 33.38],
        '赤峰': [118.87, 42.28],
        '青岛': [120.33, 36.07],
        '乳山': [121.52, 36.89],
        '金昌': [102.188043, 38.520089],
        '泉州': [118.58, 24.93],
        '莱西': [120.53, 36.86],
        '日照': [119.46, 35.42],
        '胶南': [119.97, 35.88],
        '南通': [121.05, 32.08],
        '拉萨': [91.11, 29.97],
        '云浮': [112.02, 22.93],
        '梅州': [116.1, 24.55],
        '文登': [122.05, 37.2],
        '上海': [121.48, 31.22],
        '攀枝花': [101.718637, 26.582347],
        '威海': [122.1, 37.5],
        '承德': [117.93, 40.97],
        '厦门': [118.1, 24.46],
        '汕尾': [115.375279, 22.786211],
        '潮州': [116.63, 23.68],
        '丹东': [124.37, 40.13],
        '太仓': [121.1, 31.45],
        '曲靖': [103.79, 25.51],
        '烟台': [121.39, 37.52],
        '福州': [119.3, 26.08],
        '瓦房店': [121.979603, 39.627114],
        '即墨': [120.45, 36.38],
        '抚顺': [123.97, 41.97],
        '玉溪': [102.52, 24.35],
        '张家口': [114.87, 40.82],
        '阳泉': [113.57, 37.85],
        '莱州': [119.942327, 37.177017],
        '湖州': [120.1, 30.86],
        '汕头': [116.69, 23.39],
        '昆山': [120.95, 31.39],
        '宁波': [121.56, 29.86],
        '湛江': [110.359377, 21.270708],
        '揭阳': [116.35, 23.55],
        '荣成': [122.41, 37.16],
        '连云港': [119.16, 34.59],
        '葫芦岛': [120.836932, 40.711052],
        '常熟': [120.74, 31.64],
        '东莞': [113.75, 23.04],
        '河源': [114.68, 23.73],
        '淮安': [119.15, 33.5],
        '泰州': [119.9, 32.49],
        '南宁': [108.33, 22.84],
        '营口': [122.18, 40.65],
        '惠州': [114.4, 23.09],
        '江阴': [120.26, 31.91],
        '蓬莱': [120.75, 37.8],
        '韶关': [113.62, 24.84],
        '嘉峪关': [98.289152, 39.77313],
        '广州': [113.23, 23.16],
        '延安': [109.47, 36.6],
        '太原': [112.53, 37.87],
        '清远': [113.01, 23.7],
        '中山': [113.38, 22.52],
        '昆明': [102.73, 25.04],
        '寿光': [118.73, 36.86],
        '盘锦': [122.070714, 41.119997],
        '长治': [113.08, 36.18],
        '深圳': [114.07, 22.62],
        '珠海': [113.52, 22.3],
        '宿迁': [118.3, 33.96],
        '咸阳': [108.72, 34.36],
        '铜川': [109.11, 35.09],
        '平度': [119.97, 36.77],
        '佛山': [113.11, 23.05],
        '海口': [110.35, 20.02],
        '江门': [113.06, 22.61],
        '章丘': [117.53, 36.72],
        '肇庆': [112.44, 23.05],
        '大连': [121.62, 38.92],
        '临汾': [111.5, 36.08],
        '吴江': [120.63, 31.16],
        '石嘴山': [106.39, 39.04],
        '沈阳': [123.38, 41.8],
        '苏州': [120.62, 31.32],
        '茂名': [110.88, 21.68],
        '嘉兴': [120.76, 30.77],
        '长春': [125.35, 43.88],
        '胶州': [120.03336, 36.264622],
        '银川': [106.27, 38.47],
        '张家港': [120.555821, 31.875428],
        '三门峡': [111.19, 34.76],
        '锦州': [121.15, 41.13],
        '南昌': [115.89, 28.68],
        '柳州': [109.4, 24.33],
        '三亚': [109.511909, 18.252847],
        '自贡': [104.778442, 29.33903],
        '吉林': [126.57, 43.87],
        '阳江': [111.95, 21.85],
        '泸州': [105.39, 28.91],
        '西宁': [101.74, 36.56],
        '宜宾': [104.56, 29.77],
        '呼和浩特': [111.65, 40.82],
        '成都': [104.06, 30.67],
        '大同': [113.3, 40.12],
        '镇江': [119.44, 32.2],
        '桂林': [110.28, 25.29],
        '张家界': [110.479191, 29.117096],
        '宜兴': [119.82, 31.36],
        '北海': [109.12, 21.49],
        '西安': [108.95, 34.27],
        '金坛': [119.56, 31.74],
        '东营': [118.49, 37.46],
        '牡丹江': [129.58, 44.6],
        '遵义': [106.9, 27.7],
        '绍兴': [120.58, 30.01],
        '扬州': [119.42, 32.39],
        '常州': [119.95, 31.79],
        '潍坊': [119.1, 36.62],
        '重庆': [106.54, 29.59],
        '台州': [121.420757, 28.656386],
        '南京': [118.78, 32.04],
        '滨州': [118.03, 37.36],
        '贵阳': [106.71, 26.57],
        '无锡': [120.29, 31.59],
        '本溪': [123.73, 41.3],
        '克拉玛依': [84.77, 45.59],
        '渭南': [109.5, 34.52],
        '马鞍山': [118.48, 31.56],
        '宝鸡': [107.15, 34.38],
        '焦作': [113.21, 35.24],
        '句容': [119.16, 31.95],
        '北京': [116.46, 39.92],
        '徐州': [117.2, 34.26],
        '衡水': [115.72, 37.72],
        '包头': [110, 40.58],
        '绵阳': [104.73, 31.48],
        '乌鲁木齐': [87.68, 43.77],
        '枣庄': [117.57, 34.86],
        '杭州': [120.19, 30.26],
        '淄博': [118.05, 36.78],
        '鞍山': [122.85, 41.12],
        '溧阳': [119.48, 31.43],
        '库尔勒': [86.06, 41.68],
        '安阳': [114.35, 36.1],
        '开封': [114.35, 34.79],
        '济南': [117, 36.65],
        '德阳': [104.37, 31.13],
        '温州': [120.65, 28.01],
        '九江': [115.97, 29.71],
        '邯郸': [114.47, 36.6],
        '临安': [119.72, 30.23],
        '兰州': [103.73, 36.03],
        '沧州': [116.83, 38.33],
        '临沂': [118.35, 35.05],
        '南充': [106.110698, 30.837793],
        '天津': [117.2, 39.13],
        '富阳': [119.95, 30.07],
        '泰安': [117.13, 36.18],
        '诸暨': [120.23, 29.71],
        '郑州': [113.65, 34.76],
        '哈尔滨': [126.63, 45.75],
        '聊城': [115.97, 36.45],
        '芜湖': [118.38, 31.33],
        '唐山': [118.02, 39.63],
        '平顶山': [113.29, 33.75],
        '邢台': [114.48, 37.05],
        '德州': [116.29, 37.45],
        '济宁': [116.59, 35.38],
        '荆州': [112.239741, 30.335165],
        '宜昌': [111.3, 30.7],
        '义乌': [120.06, 29.32],
        '丽水': [119.92, 28.45],
        '洛阳': [112.44, 34.7],
        '秦皇岛': [119.57, 39.95],
        '株洲': [113.16, 27.83],
        '石家庄': [114.48, 38.03],
        '莱芜': [117.67, 36.19],
        '常德': [111.69, 29.05],
        '保定': [115.48, 38.85],
        '湘潭': [112.91, 27.87],
        '金华': [119.64, 29.12],
        '岳阳': [113.09, 29.37],
        '长沙': [113, 28.21],
        '衢州': [118.88, 28.97],
        '廊坊': [116.7, 39.53],
        '菏泽': [115.480656, 35.23375],
        '合肥': [117.27, 31.86],
        '武汉': [114.31, 30.52],
        '大庆': [125.03, 46.58]
    };

    function convertData(data) {
        var res = [];
        for (var i = 0; i < data.length; i++) {
            var geoCoord = geoCoordMap[data[i].name];
            if (geoCoord) {
                res.push({
                    name: data[i].name,
                    value: geoCoord.concat(data[i].value)
                });
            }
        }
        return res;
    };

    function randomValue() {
        return Math.round(Math.random() * 1000);
    }


    option = {
        tooltip: {},
        visualMap: {
            min: 0,
            max: 1500,
            left: 'left',
            top: 'bottom',
            text: ['高', '低'],
            seriesIndex: [1],
            inRange: {
                color: ['#e0ffff', '#006edd']
            },
            textStyle: {
                color: '#006edd'
            },
            calculable: true
        },
        geo: {
            map: 'china',
            roam: true,
            label: {
                normal: {
                    show: false,
                    textStyle: {
                        color: 'rgba(0,0,0,0.4)'
                    }
                }
            },
            itemStyle: {
                normal: {
                    borderColor: 'rgba(0, 0, 0, 0.2)'
                },
                emphasis: {
                    areaColor: null,
                    shadowOffsetX: 0,
                    shadowOffsetY: 0,
                    shadowBlur: 20,
                    borderWidth: 0,
                    shadowColor: 'rgba(0, 0, 0, 0.5)'
                }
            }
        },
        series: [
            {
                type: 'scatter',
                coordinateSystem: 'geo',
                data: convertData(data),
                symbolSize: 0,

                symbol: 'image://imgs/pe.png',
//                symbol: '23',
//

                symbolRotate: 25,
                label: {
                    normal: {
                        formatter: '{b}',
                        position: 'right',
                        show: false
                    },
                    emphasis: {
                        show: true
                    }
                },
                itemStyle: {
                    normal: {
//                        color: '#F06C00'
                    }
                }
            },
            {
                name: '',
                type: 'map',
                geoIndex: 0,
                // tooltip: {show: false},
                data:province

            }
        ]
    };
    myChart.setOption(option);
    })
    //客流量分析
    $.get("statistics/futureOneMonth/" + time + "/" + sdate + "/" + udate, function (request) {
    var myChart = echarts.init(document.getElementById('kllfx'));
    option = {
        tooltip: {
            trigger: 'axis',
            axisPointer: {
                lineStyle: {
                    color: '#57617B'
                }
            }
        },
        legend: {
            icon: 'rect',
            itemWidth: 14,
            itemHeight: 5,
            itemGap: 13,
            data: ['增长数'],
            right: '4%',
            textStyle: {
                fontSize: 12,
                color: '#F1F1F3'
            }
        },
        grid: {
            left: '3%',
            right: '4%',
            bottom: '3%',
            containLabel: true
        },
        xAxis: [{
            type: 'category',
            boundaryGap: false,
            axisLine: {
                lineStyle: {
                    color: '#00c7ff'
                }
            },
            data: ['未来第一月', '未来第二月', '未来第三月', '未来第四月', '未来第五月', '未来第六月']
        }],
        yAxis: [{
            type: 'value',
            axisTick: {
                show: false
            },
            axisLine: {
                lineStyle: {
                    color: '#00c7ff'
                }
            },
            axisLabel: {
                margin: 10,
                textStyle: {
                    fontSize: 14
                }
            },
            splitLine: {
                show: false
            }
        }],
        series: [{
            name: '增长数',
            type: 'line',
            smooth: true,
            symbol: 'circle',
            symbolSize: 5,
            showSymbol: false,
            lineStyle: {
                normal: {
                    width: 1
                }
            },
            areaStyle: {
                normal: {
                    color: new echarts.graphic.LinearGradient(0, 0, 0, 1, [{
                        offset: 0,
                        color: '#5ff6e9'
                    }, {
                        offset: 0.8,
                        color: '#7370fd'
                    }], false),
                    shadowColor: 'rgba(0, 0, 0, 0.1)',
                    shadowBlur: 10
                }
            },
            itemStyle: {
                normal: {
                    color: 'rgb(137,189,27)',
                    borderColor: 'rgba(137,189,2,0.27)',
                    borderWidth: 12

                }
            },
            data: request
        }]
    };
    myChart.setOption(option);
    })
    //词云展示
    var myChart = echarts.init(document.getElementById('cyzss'));
    option = {
        title: {
            text: ''
        },
        tooltip: {},
        animationDurationUpdate: 1500,
        animationEasingUpdate: 'quinticInOut',
        color: ['#83e0ff', '#45f5ce', '#b158ff'],
        legend: {
            show: true,
            data: [
                {name: '', textStyle: {color: '#fff'}},
                {name: '', textStyle: {color: '#fff'}},
                {name: '', textStyle: {color: '#fff'}}
            ]
        },
        series: [
            {
                type: 'graph',
                layout: 'force',
                force: {
                    repulsion: 1000,
                    edgeLength: 50
                },
                symbolSize: 50,
                roam: true,
                label: {
                    normal: {
                        show: true
                    }
                },
                edgeSymbolSize: [4, 10],
                edgeLabel: {
                    normal: {
                        show: true,
                        textStyle: {
                            fontSize: 13
                        },
                        formatter: "{c}"
                    }
                },

                data: [
                    {
                        name: '说明',

                        symbolSize: 100,
                        draggable: true,
                        category: 1,
                        itemStyle: {
                            normal: {
                                borderColor: '#04f2a7',
                                borderWidth: 6,
                                shadowBlur: 20,
                                shadowColor: '#04f2a7',
                                color: '#001c43',
                            }
                        }
                    },
                    {
                        name: '刀',
                        symbolSize: 70,
                        itemStyle: {
                            normal: {
                                borderColor: '#04f2a7',
                                borderWidth: 4,
                                shadowBlur: 10,
                                shadowColor: '#04f2a7',
                                color: '#001c43',
                            }
                        },
                        category: 1,

                    },
                    {
                        name: '指纹',
                        symbolSize: 70,
                        category: 1,
                        itemStyle: {
                            normal: {
                                borderColor: '#04f2a7',
                                borderWidth: 4,
                                shadowBlur: 10,
                                shadowColor: '#04f2a7',
                                color: '#001c43',
                            }
                        },

                    },
                    {
                        name: '张三',
                        symbolSize: 70,
                        category: 0,
                        itemStyle: {
                            normal: {
                                borderColor: '#82dffe',
                                borderWidth: 4,
                                shadowBlur: 10,
                                shadowColor: '#04f2a7',
                                color: '#001c43',
                            }
                        },

                    },
                    {
                        name: '李四',
                        symbolSize: 70,
                        category: 0,
                        itemStyle: {
                            normal: {
                                borderColor: '#82dffe',
                                borderWidth: 4,
                                shadowBlur: 10,
                                shadowColor: '#04f2a7',
                                color: '#001c43',
                            }
                        },

                    },
                    {
                        name: '张三2',
                        category: 0,
                        itemStyle: {
                            normal: {
                                borderColor: '#82dffe',
                                borderWidth: 4,
                                shadowBlur: 10,
                                shadowColor: '#04f2a7',
                                color: '#001c43',
                            }
                        },

                    },
                    {
                        name: '无名尸',
                        category: 2,
                        itemStyle: {
                            normal: {
                                borderColor: '#b457ff',
                                borderWidth: 4,
                                shadowBlur: 10,
                                shadowColor: '#b457ff',
                                color: '#001c43'
                            }
                        },

                    },
                    {
                        name: '赖子',
                        itemStyle: {
                            normal: {
                                borderColor: '#82dffe',
                                borderWidth: 4,
                                shadowBlur: 10,
                                shadowColor: '#04f2a7',
                                color: '#001c43'

                            }
                        },
                        category: 0,

                    },
                    {
                        name: '王五',
                        itemStyle: {
                            normal: {
                                borderColor: '#82dffe',
                                borderWidth: 4,
                                shadowBlur: 10,
                                shadowColor: '#04f2a7',
                                color: '#001c43'
                            }
                        },
                        category: 0,

                    },
                    {
                        name: '刘大',
                        category: 0,
                        itemStyle: {
                            normal: {
                                borderColor: '#82dffe',
                                borderWidth: 4,
                                shadowBlur: 10,
                                shadowColor: '#04f2a7',
                                color: '#001c43'
                            }
                        },

                    }],
                links: [
                    {
                        source: '说明',
                        target: '刀',
                        value: '',
                        lineStyle: {
                            normal: {
                                color: {
                                    type: 'linear',
                                    x: 0,
                                    y: 0,
                                    x2: 0,
                                    y2: 1,
                                    colorStops: [{
                                        offset: 0, color: '#e0f55a' // 0% 处的颜色
                                    }, {
                                        offset: 1, color: '#639564' // 100% 处的颜色
                                    }],
                                    globalCoord: false // 缺省为 false
                                }
                            }
                        }

                    },
                    {
                        source: '说明',
                        target: '指纹',
                        value: '',
                        lineStyle: {
                            normal: {
                                color: {
                                    type: 'linear',
                                    x: 0,
                                    y: 0,
                                    x2: 0,
                                    y2: 1,
                                    colorStops: [{
                                        offset: 0, color: '#eda553' // 0% 处的颜色
                                    }, {
                                        offset: 1, color: '#7c785b' // 100% 处的颜色
                                    }],
                                    globalCoord: false // 缺省为 false
                                }
                            }
                        },
                    },
                    {
                        source: '说明',
                        target: '张三',
                        value: '',
                        lineStyle: {
                            normal: {
                                color: {
                                    type: 'linear',
                                    x: 0,
                                    y: 0,
                                    x2: 0,
                                    y2: 1,
                                    colorStops: [{
                                        offset: 0, color: '#eda553' // 0% 处的颜色
                                    }, {
                                        offset: 1, color: '#7c785b' // 100% 处的颜色
                                    }],
                                    globalCoord: false // 缺省为 false
                                }
                            }
                        },
                    },
                    {
                        source: '说明',
                        target: '李四',
                        value: '',
                        lineStyle: {
                            normal: {
                                color: {
                                    type: 'linear',
                                    x: 0,
                                    y: 0,
                                    x2: 0,
                                    y2: 1,
                                    colorStops: [{
                                        offset: 0, color: '#e0f55a' // 0% 处的颜色
                                    }, {
                                        offset: 1, color: '#639564' // 100% 处的颜色
                                    }],
                                    globalCoord: false // 缺省为 false
                                }
                            }
                        }
                    },
                    {
                        source: '说明',
                        target: '张三'
                    },
                    {
                        source: '刀',
                        target: '张三2',
                        value: '',
                        lineStyle: {
                            normal: {
                                color: {
                                    type: 'linear',
                                    x: 0,
                                    y: 0,
                                    x2: 0,
                                    y2: 1,
                                    colorStops: [{
                                        offset: 0, color: '#e0f55a' // 0% 处的颜色
                                    }, {
                                        offset: 1, color: '#639564' // 100% 处的颜色
                                    }],
                                    globalCoord: false // 缺省为 false
                                }
                            }
                        }
                    },
                    {
                        source: '刀',
                        target: '无名尸', value: '',
                        lineStyle: {
                            normal: {
                                color: {
                                    type: 'linear',
                                    x: 0,
                                    y: 0,
                                    x2: 0,
                                    y2: 1,
                                    colorStops: [{
                                        offset: 0, color: '#e0f55a' // 0% 处的颜色
                                    }, {
                                        offset: 1, color: '#639564' // 100% 处的颜色
                                    }],
                                    globalCoord: false // 缺省为 false
                                }
                            }
                        }

                    },
                    {
                        source: '李四',
                        target: '赖子',
                        value: '',
                        lineStyle: {
                            normal: {
                                color: {
                                    type: 'linear',
                                    x: 0,
                                    y: 0,
                                    x2: 0,
                                    y2: 1,
                                    colorStops: [{
                                        offset: 0, color: '#e0f55a' // 0% 处的颜色
                                    }, {
                                        offset: 1, color: '#639564' // 100% 处的颜色
                                    }],
                                    globalCoord: false // 缺省为 false
                                }
                            }
                        }
                    },
                    {
                        source: '李四',
                        target: '王五',
                        value: '',
                        lineStyle: {
                            normal: {
                                color: {
                                    type: 'linear',
                                    x: 0,
                                    y: 0,
                                    x2: 0,
                                    y2: 1,
                                    colorStops: [{
                                        offset: 0, color: '#df6f30' // 0% 处的颜色
                                    }, {
                                        offset: 1, color: '#915034' // 100% 处的颜色
                                    }],
                                    globalCoord: false // 缺省为 false
                                }
                            }
                        },
                    },
                    {
                        source: '王五',
                        target: '刘大',
                        value: '',
                        lineStyle: {
                            normal: {
                                color: {
                                    type: 'linear',
                                    x: 0,
                                    y: 0,
                                    x2: 0,
                                    y2: 1,
                                    colorStops: [{
                                        offset: 0, color: '#eda553' // 0% 处的颜色
                                    }, {
                                        offset: 1, color: '#7c785b' // 100% 处的颜色
                                    }],
                                    globalCoord: false // 缺省为 false
                                }
                            }
                        },
                    }
                ],
                lineStyle: {
                    normal: {
                        opacity: 0.9,
                        width: 5,
                        curveness: 0
                    }
                },
                categories: [
                    {name: '人'},
                    {name: '物证'},
                    {name: '不明物体'}
                ]
            }
        ]
    }
    myChart.setOption(option);
    //客流量统计
    $.get("statistics/passengerStatistics/" + time + "/" + sdate + "/" + udate, function (request) {
        var myChart = echarts.init(document.getElementById('klltj'));
        option = {
            tooltip: {
                trigger: 'axis',
                axisPointer: {
                    type: 'shadow'
                }
            },
            legend: {
                data: ['男性', '女性'],
                align: 'right',
                right: 10,
                textStyle: {
                    color: "#fff"
                },
                itemWidth: 10,
                itemHeight: 10,
                itemGap: 35
            },
            grid: {
                left: '3%',
                right: '4%',
                bottom: '3%',
                containLabel: true
            },
            xAxis: [{
                type: 'category',
                data: request.province,
                axisLine: {
                    show: true,
                    lineStyle: {
                        color: "#063374",
                        width: 1,
                        type: "solid"
                    }
                },
                axisTick: {
                    show: false,
                },
                axisLabel: {
                    show: true,
                    textStyle: {
                        color: "#00c7ff",
                    }
                },
            }],
            yAxis: [{
                type: 'value',
                axisLabel: {
                    formatter: '{value}'
                },
                axisTick: {
                    show: false,
                },
                axisLine: {
                    show: false,
                    lineStyle: {
                        color: "#00c7ff",
                        width: 1,
                        type: "solid"
                    },
                },
                splitLine: {
                    lineStyle: {
                        color: "#063374",
                    }
                }
            }],
            series: [{
                name: '男性',
                type: 'bar',
                data: request.man,
                barWidth: 10, //柱子宽度
                barGap: 1, //柱子之间间距
                itemStyle: {
                    normal: {
                        color: new echarts.graphic.LinearGradient(0, 0, 0, 1, [{
                            offset: 0,
                            color: '#008cff'
                        }, {
                            offset: 1,
                            color: '#005193'
                        }]),
                        opacity: 1,
                    }
                }
            }, {
                name: '女性',
                type: 'bar',
                data: request.woman,
                barWidth: 10,
                barGap: 1,
                itemStyle: {
                    normal: {
                        color: new echarts.graphic.LinearGradient(0, 0, 0, 1, [{
                            offset: 0,
                            color: '#00da9c'
                        }, {
                            offset: 1,
                            color: '#007a55'
                        }]),
                        opacity: 1,
                    }
                }
            }
                /*, {
            name: '完好率',
            type: 'bar',
            data: [47, 50, 72, 96, 86],
            barWidth: 10,
            barGap: 1,
            itemStyle: {
                normal: {
                    color: new echarts.graphic.LinearGradient(0, 0, 0, 1, [{
                        offset: 0,
                        color: '#c4e300'
                    }, {
                        offset: 1,
                        color: '#728400'
                    }]),
                    opacity: 1,
                }
            }
        }*/]
    };
    myChart.setOption(option);
    });
    function back() {
        $('html').load(/*[[@{/login}]]*/"./login.html")
    }
    function set(obj){
        time=obj;
        $("#sdate").val("0");
        $("#udate").val("0");
        $("#test6").val("");
        var sdate=$("#sdate").val();
        var udate=$("#udate").val();
        //评价展示
//        $.get("/statistics/findAppraiseList/"+time, function (request) {
//            console.log(request);
//            var html ="";
//            $.each(request,function (index,item) {
//                html +="<ul class='ultext'> <li class='li1'> "+item.name+"</li> <li class='li2'>"+item.star+"</li> <li class='li3'>"+item.content+"</li> </ul>";
//            })
//            $("#appraise").empty();
//            $("#appraise").append(html);
//        });
//            $('html').load(/*[[@{/screen}]]*/"./static/static.html")
        //当前客流总量
        $.get("statistics/current/" + time + "/" + sdate + "/" + udate, function (request) {
            $("#null").empty()
            $("#null").append("<div style=\"color:#22d1e4;font-size:2vw\">" + request + "</div>")
        });
        //年龄占比
        $.get("statistics/age/" + time + "/" + sdate + "/" + udate, function (request) {
            var sum = 0;
            for(var i=0;i<request.length;i++){
                sum += request[i];
            }
            var myChart = echarts.init(document.getElementById('nlzb'));
            option = {
                xAxis: {
                    data: ['0~10', '10~20', '20~30', '30~40', '40~50', '50~60', '60~70', '70~80', '80~90', '90~100'],
                    axisLine: {
                        lineStyle: {
                            color: '#0177d4'
                        }
                    },
                    axisLabel: {
                        color: '#fff',
                        fontSize: 14
                    }
                },
                yAxis: {
                    name: "（人）",
                    nameTextStyle: {
                        color: '#fff',
                        fontSize: 16
                    },
                    axisLine: {
                        lineStyle: {
                            color: '#0177d4'
                        }
                    },
                    axisLabel: {
                        color: '#fff',
                        fontSize: 16
                    },
                    splitLine: {
                        show: false,
                        lineStyle: {
                            color: '#0177d4'
                        }
                    },
                    interval: sum/10,
                    max: sum
                },
                series: [{
                    type: 'bar',
                    barWidth: 18,
                    itemStyle: {
                        normal: {
                            color: new echarts.graphic.LinearGradient(0, 0, 0, 1, [{
                                offset: 0,
                                color: '#00b0ff'
                            }, {
                                offset: 0.8,
                                color: '#7052f4'
                            }], false)
                        }
                    },
                    data: request
                }]
            };
            myChart.setOption(option);
        });
        //性别占比
        $.get("statistics/sex/" + time + "/" + sdate + "/" + udate, function (request) {
            var count = request.manCount+request.womanCount;
            var woman = request.womanCount/count;
            var man = request.manCount/count;
            var womanCount = [woman,0.5,0.4,0.3]
            var manCount = [man,0.5,0.4,0.3]

            var myChart = echarts.init(document.getElementById('nan'));
            option = {
                series: [{
                    type: 'liquidFill',
                    data: manCount,
                    radius: '80%'
                }]
            };
            myChart.setOption(option);
            var myChart = echarts.init(document.getElementById('nv'));
            option = {
                series: [{
                    type: 'liquidFill',
                    data: womanCount,
                    radius: '80%'

                }]
            };
            myChart.setOption(option);
        })
        //各省参观人数
        $.get("statistics/province/" + time + "/" + sdate + "/" + udate, function (request) {
            var province = [];
            $(request).each(function (x, y) {
                province.push({name:y.regionName,value:y.count})
            })

            var myChart = echarts.init(document.getElementById('main'));

            var data = [
                {name: '海门', value: 9},
                {name: '鄂尔多斯', value: 12},
                {name: '招远', value: 12},
                {name: '舟山', value: 12},
                {name: '齐齐哈尔', value: 14},
                {name: '盐城', value: 15},
                {name: '赤峰', value: 16},
                {name: '青岛', value: 18},
                {name: '乳山', value: 18},
                {name: '金昌', value: 19},
                {name: '泉州', value: 21},
                {name: '南通', value: 23},
                {name: '拉萨', value: 24},
                {name: '云浮', value: 24},
                {name: '上海', value: 25},
                {name: '攀枝花', value: 25},
                {name: '承德', value: 25},
                {name: '汕尾', value: 26},
                {name: '丹东', value: 27},
                {name: '瓦房店', value: 30},
                {name: '延安', value: 38},
                {name: '咸阳', value: 43},
                {name: '南昌', value: 54},
                {name: '柳州', value: 54},
                {name: '三亚', value: 54},
                {name: '泸州', value: 57},
                {name: '克拉玛依', value: 72}
            ];

            var geoCoordMap = {
                '海门': [121.15, 31.89],
                '鄂尔多斯': [109.781327, 39.608266],
                '招远': [120.38, 37.35],
                '舟山': [122.207216, 29.985295],
                '齐齐哈尔': [123.97, 47.33],
                '盐城': [120.13, 33.38],
                '赤峰': [118.87, 42.28],
                '青岛': [120.33, 36.07],
                '乳山': [121.52, 36.89],
                '金昌': [102.188043, 38.520089],
                '泉州': [118.58, 24.93],
                '莱西': [120.53, 36.86],
                '日照': [119.46, 35.42],
                '胶南': [119.97, 35.88],
                '南通': [121.05, 32.08],
                '拉萨': [91.11, 29.97],
                '云浮': [112.02, 22.93],
                '梅州': [116.1, 24.55],
                '文登': [122.05, 37.2],
                '上海': [121.48, 31.22],
                '攀枝花': [101.718637, 26.582347],
                '威海': [122.1, 37.5],
                '承德': [117.93, 40.97],
                '厦门': [118.1, 24.46],
                '汕尾': [115.375279, 22.786211],
                '潮州': [116.63, 23.68],
                '丹东': [124.37, 40.13],
                '太仓': [121.1, 31.45],
                '曲靖': [103.79, 25.51],
                '烟台': [121.39, 37.52],
                '福州': [119.3, 26.08],
                '瓦房店': [121.979603, 39.627114],
                '即墨': [120.45, 36.38],
                '抚顺': [123.97, 41.97],
                '玉溪': [102.52, 24.35],
                '张家口': [114.87, 40.82],
                '阳泉': [113.57, 37.85],
                '莱州': [119.942327, 37.177017],
                '湖州': [120.1, 30.86],
                '汕头': [116.69, 23.39],
                '昆山': [120.95, 31.39],
                '宁波': [121.56, 29.86],
                '湛江': [110.359377, 21.270708],
                '揭阳': [116.35, 23.55],
                '荣成': [122.41, 37.16],
                '连云港': [119.16, 34.59],
                '葫芦岛': [120.836932, 40.711052],
                '常熟': [120.74, 31.64],
                '东莞': [113.75, 23.04],
                '河源': [114.68, 23.73],
                '淮安': [119.15, 33.5],
                '泰州': [119.9, 32.49],
                '南宁': [108.33, 22.84],
                '营口': [122.18, 40.65],
                '惠州': [114.4, 23.09],
                '江阴': [120.26, 31.91],
                '蓬莱': [120.75, 37.8],
                '韶关': [113.62, 24.84],
                '嘉峪关': [98.289152, 39.77313],
                '广州': [113.23, 23.16],
                '延安': [109.47, 36.6],
                '太原': [112.53, 37.87],
                '清远': [113.01, 23.7],
                '中山': [113.38, 22.52],
                '昆明': [102.73, 25.04],
                '寿光': [118.73, 36.86],
                '盘锦': [122.070714, 41.119997],
                '长治': [113.08, 36.18],
                '深圳': [114.07, 22.62],
                '珠海': [113.52, 22.3],
                '宿迁': [118.3, 33.96],
                '咸阳': [108.72, 34.36],
                '铜川': [109.11, 35.09],
                '平度': [119.97, 36.77],
                '佛山': [113.11, 23.05],
                '海口': [110.35, 20.02],
                '江门': [113.06, 22.61],
                '章丘': [117.53, 36.72],
                '肇庆': [112.44, 23.05],
                '大连': [121.62, 38.92],
                '临汾': [111.5, 36.08],
                '吴江': [120.63, 31.16],
                '石嘴山': [106.39, 39.04],
                '沈阳': [123.38, 41.8],
                '苏州': [120.62, 31.32],
                '茂名': [110.88, 21.68],
                '嘉兴': [120.76, 30.77],
                '长春': [125.35, 43.88],
                '胶州': [120.03336, 36.264622],
                '银川': [106.27, 38.47],
                '张家港': [120.555821, 31.875428],
                '三门峡': [111.19, 34.76],
                '锦州': [121.15, 41.13],
                '南昌': [115.89, 28.68],
                '柳州': [109.4, 24.33],
                '三亚': [109.511909, 18.252847],
                '自贡': [104.778442, 29.33903],
                '吉林': [126.57, 43.87],
                '阳江': [111.95, 21.85],
                '泸州': [105.39, 28.91],
                '西宁': [101.74, 36.56],
                '宜宾': [104.56, 29.77],
                '呼和浩特': [111.65, 40.82],
                '成都': [104.06, 30.67],
                '大同': [113.3, 40.12],
                '镇江': [119.44, 32.2],
                '桂林': [110.28, 25.29],
                '张家界': [110.479191, 29.117096],
                '宜兴': [119.82, 31.36],
                '北海': [109.12, 21.49],
                '西安': [108.95, 34.27],
                '金坛': [119.56, 31.74],
                '东营': [118.49, 37.46],
                '牡丹江': [129.58, 44.6],
                '遵义': [106.9, 27.7],
                '绍兴': [120.58, 30.01],
                '扬州': [119.42, 32.39],
                '常州': [119.95, 31.79],
                '潍坊': [119.1, 36.62],
                '重庆': [106.54, 29.59],
                '台州': [121.420757, 28.656386],
                '南京': [118.78, 32.04],
                '滨州': [118.03, 37.36],
                '贵阳': [106.71, 26.57],
                '无锡': [120.29, 31.59],
                '本溪': [123.73, 41.3],
                '克拉玛依': [84.77, 45.59],
                '渭南': [109.5, 34.52],
                '马鞍山': [118.48, 31.56],
                '宝鸡': [107.15, 34.38],
                '焦作': [113.21, 35.24],
                '句容': [119.16, 31.95],
                '北京': [116.46, 39.92],
                '徐州': [117.2, 34.26],
                '衡水': [115.72, 37.72],
                '包头': [110, 40.58],
                '绵阳': [104.73, 31.48],
                '乌鲁木齐': [87.68, 43.77],
                '枣庄': [117.57, 34.86],
                '杭州': [120.19, 30.26],
                '淄博': [118.05, 36.78],
                '鞍山': [122.85, 41.12],
                '溧阳': [119.48, 31.43],
                '库尔勒': [86.06, 41.68],
                '安阳': [114.35, 36.1],
                '开封': [114.35, 34.79],
                '济南': [117, 36.65],
                '德阳': [104.37, 31.13],
                '温州': [120.65, 28.01],
                '九江': [115.97, 29.71],
                '邯郸': [114.47, 36.6],
                '临安': [119.72, 30.23],
                '兰州': [103.73, 36.03],
                '沧州': [116.83, 38.33],
                '临沂': [118.35, 35.05],
                '南充': [106.110698, 30.837793],
                '天津': [117.2, 39.13],
                '富阳': [119.95, 30.07],
                '泰安': [117.13, 36.18],
                '诸暨': [120.23, 29.71],
                '郑州': [113.65, 34.76],
                '哈尔滨': [126.63, 45.75],
                '聊城': [115.97, 36.45],
                '芜湖': [118.38, 31.33],
                '唐山': [118.02, 39.63],
                '平顶山': [113.29, 33.75],
                '邢台': [114.48, 37.05],
                '德州': [116.29, 37.45],
                '济宁': [116.59, 35.38],
                '荆州': [112.239741, 30.335165],
                '宜昌': [111.3, 30.7],
                '义乌': [120.06, 29.32],
                '丽水': [119.92, 28.45],
                '洛阳': [112.44, 34.7],
                '秦皇岛': [119.57, 39.95],
                '株洲': [113.16, 27.83],
                '石家庄': [114.48, 38.03],
                '莱芜': [117.67, 36.19],
                '常德': [111.69, 29.05],
                '保定': [115.48, 38.85],
                '湘潭': [112.91, 27.87],
                '金华': [119.64, 29.12],
                '岳阳': [113.09, 29.37],
                '长沙': [113, 28.21],
                '衢州': [118.88, 28.97],
                '廊坊': [116.7, 39.53],
                '菏泽': [115.480656, 35.23375],
                '合肥': [117.27, 31.86],
                '武汉': [114.31, 30.52],
                '大庆': [125.03, 46.58]
            };

            function convertData(data) {
                var res = [];
                for (var i = 0; i < data.length; i++) {
                    var geoCoord = geoCoordMap[data[i].name];
                    if (geoCoord) {
                        res.push({
                            name: data[i].name,
                            value: geoCoord.concat(data[i].value)
                        });
                    }
                }
                return res;
            };

            function randomValue() {
                return Math.round(Math.random() * 1000);
            }


            option = {
                tooltip: {},
                visualMap: {
                    min: 0,
                    max: 1500,
                    left: 'left',
                    top: 'bottom',
                    text: ['高', '低'],
                    seriesIndex: [1],
                    inRange: {
                        color: ['#e0ffff', '#006edd']
                    },
                    textStyle: {
                        color: '#006edd'
                    },
                    calculable: true
                },
                geo: {
                    map: 'china',
                    roam: true,
                    label: {
                        normal: {
                            show: false,
                            textStyle: {
                                color: 'rgba(0,0,0,0.4)'
                            }
                        }
                    },
                    itemStyle: {
                        normal: {
                            borderColor: 'rgba(0, 0, 0, 0.2)'
                        },
                        emphasis: {
                            areaColor: null,
                            shadowOffsetX: 0,
                            shadowOffsetY: 0,
                            shadowBlur: 20,
                            borderWidth: 0,
                            shadowColor: 'rgba(0, 0, 0, 0.5)'
                        }
                    }
                },
                series: [
                    {
                        type: 'scatter',
                        coordinateSystem: 'geo',
                        data: convertData(data),
                        symbolSize: 0,

                        symbol: 'image://imgs/pe.png',
//                symbol: '23',
//

                        symbolRotate: 25,
                        label: {
                            normal: {
                                formatter: '{b}',
                                position: 'right',
                                show: false
                            },
                            emphasis: {
                                show: true
                            }
                        },
                        itemStyle: {
                            normal: {
//                        color: '#F06C00'
                            }
                        }
                    },
                    {
                        name: '',
                        type: 'map',
                        geoIndex: 0,
                        // tooltip: {show: false},
                        data:province

                    }
                ]
            };
            myChart.setOption(option);
        })

        //词云展示
        var myChart = echarts.init(document.getElementById('cyzss'));
        option = {
            title: {
                text: ''
            },
            tooltip: {},
            animationDurationUpdate: 1500,
            animationEasingUpdate: 'quinticInOut',
            color: ['#83e0ff', '#45f5ce', '#b158ff'],
            legend: {
                show: true,
                data: [
                    {name: '', textStyle: {color: '#fff'}},
                    {name: '', textStyle: {color: '#fff'}},
                    {name: '', textStyle: {color: '#fff'}}
                ]
            },
            series: [
                {
                    type: 'graph',
                    layout: 'force',
                    force: {
                        repulsion: 1000,
                        edgeLength: 50
                    },
                    symbolSize: 50,
                    roam: true,
                    label: {
                        normal: {
                            show: true
                        }
                    },
                    edgeSymbolSize: [4, 10],
                    edgeLabel: {
                        normal: {
                            show: true,
                            textStyle: {
                                fontSize: 13
                            },
                            formatter: "{c}"
                        }
                    },

                    data: [
                        {
                            name: '说明',

                            symbolSize: 100,
                            draggable: true,
                            category: 1,
                            itemStyle: {
                                normal: {
                                    borderColor: '#04f2a7',
                                    borderWidth: 6,
                                    shadowBlur: 20,
                                    shadowColor: '#04f2a7',
                                    color: '#001c43',
                                }
                            }
                        },
                        {
                            name: '刀',
                            symbolSize: 70,
                            itemStyle: {
                                normal: {
                                    borderColor: '#04f2a7',
                                    borderWidth: 4,
                                    shadowBlur: 10,
                                    shadowColor: '#04f2a7',
                                    color: '#001c43',
                                }
                            },
                            category: 1,

                        },
                        {
                            name: '指纹',
                            symbolSize: 70,
                            category: 1,
                            itemStyle: {
                                normal: {
                                    borderColor: '#04f2a7',
                                    borderWidth: 4,
                                    shadowBlur: 10,
                                    shadowColor: '#04f2a7',
                                    color: '#001c43',
                                }
                            },

                        },
                        {
                            name: '张三',
                            symbolSize: 70,
                            category: 0,
                            itemStyle: {
                                normal: {
                                    borderColor: '#82dffe',
                                    borderWidth: 4,
                                    shadowBlur: 10,
                                    shadowColor: '#04f2a7',
                                    color: '#001c43',
                                }
                            },

                        },
                        {
                            name: '李四',
                            symbolSize: 70,
                            category: 0,
                            itemStyle: {
                                normal: {
                                    borderColor: '#82dffe',
                                    borderWidth: 4,
                                    shadowBlur: 10,
                                    shadowColor: '#04f2a7',
                                    color: '#001c43',
                                }
                            },

                        },
                        {
                            name: '张三2',
                            category: 0,
                            itemStyle: {
                                normal: {
                                    borderColor: '#82dffe',
                                    borderWidth: 4,
                                    shadowBlur: 10,
                                    shadowColor: '#04f2a7',
                                    color: '#001c43',
                                }
                            },

                        },
                        {
                            name: '无名尸',
                            category: 2,
                            itemStyle: {
                                normal: {
                                    borderColor: '#b457ff',
                                    borderWidth: 4,
                                    shadowBlur: 10,
                                    shadowColor: '#b457ff',
                                    color: '#001c43'
                                }
                            },

                        },
                        {
                            name: '赖子',
                            itemStyle: {
                                normal: {
                                    borderColor: '#82dffe',
                                    borderWidth: 4,
                                    shadowBlur: 10,
                                    shadowColor: '#04f2a7',
                                    color: '#001c43'

                                }
                            },
                            category: 0,

                        },
                        {
                            name: '王五',
                            itemStyle: {
                                normal: {
                                    borderColor: '#82dffe',
                                    borderWidth: 4,
                                    shadowBlur: 10,
                                    shadowColor: '#04f2a7',
                                    color: '#001c43'
                                }
                            },
                            category: 0,

                        },
                        {
                            name: '刘大',
                            category: 0,
                            itemStyle: {
                                normal: {
                                    borderColor: '#82dffe',
                                    borderWidth: 4,
                                    shadowBlur: 10,
                                    shadowColor: '#04f2a7',
                                    color: '#001c43'
                                }
                            },

                        }],
                    links: [
                        {
                            source: '说明',
                            target: '刀',
                            value: '',
                            lineStyle: {
                                normal: {
                                    color: {
                                        type: 'linear',
                                        x: 0,
                                        y: 0,
                                        x2: 0,
                                        y2: 1,
                                        colorStops: [{
                                            offset: 0, color: '#e0f55a' // 0% 处的颜色
                                        }, {
                                            offset: 1, color: '#639564' // 100% 处的颜色
                                        }],
                                        globalCoord: false // 缺省为 false
                                    }
                                }
                            }

                        },
                        {
                            source: '说明',
                            target: '指纹',
                            value: '',
                            lineStyle: {
                                normal: {
                                    color: {
                                        type: 'linear',
                                        x: 0,
                                        y: 0,
                                        x2: 0,
                                        y2: 1,
                                        colorStops: [{
                                            offset: 0, color: '#eda553' // 0% 处的颜色
                                        }, {
                                            offset: 1, color: '#7c785b' // 100% 处的颜色
                                        }],
                                        globalCoord: false // 缺省为 false
                                    }
                                }
                            },
                        },
                        {
                            source: '说明',
                            target: '张三',
                            value: '',
                            lineStyle: {
                                normal: {
                                    color: {
                                        type: 'linear',
                                        x: 0,
                                        y: 0,
                                        x2: 0,
                                        y2: 1,
                                        colorStops: [{
                                            offset: 0, color: '#eda553' // 0% 处的颜色
                                        }, {
                                            offset: 1, color: '#7c785b' // 100% 处的颜色
                                        }],
                                        globalCoord: false // 缺省为 false
                                    }
                                }
                            },
                        },
                        {
                            source: '说明',
                            target: '李四',
                            value: '',
                            lineStyle: {
                                normal: {
                                    color: {
                                        type: 'linear',
                                        x: 0,
                                        y: 0,
                                        x2: 0,
                                        y2: 1,
                                        colorStops: [{
                                            offset: 0, color: '#e0f55a' // 0% 处的颜色
                                        }, {
                                            offset: 1, color: '#639564' // 100% 处的颜色
                                        }],
                                        globalCoord: false // 缺省为 false
                                    }
                                }
                            }
                        },
                        {
                            source: '说明',
                            target: '张三'
                        },
                        {
                            source: '刀',
                            target: '张三2',
                            value: '',
                            lineStyle: {
                                normal: {
                                    color: {
                                        type: 'linear',
                                        x: 0,
                                        y: 0,
                                        x2: 0,
                                        y2: 1,
                                        colorStops: [{
                                            offset: 0, color: '#e0f55a' // 0% 处的颜色
                                        }, {
                                            offset: 1, color: '#639564' // 100% 处的颜色
                                        }],
                                        globalCoord: false // 缺省为 false
                                    }
                                }
                            }
                        },
                        {
                            source: '刀',
                            target: '无名尸', value: '',
                            lineStyle: {
                                normal: {
                                    color: {
                                        type: 'linear',
                                        x: 0,
                                        y: 0,
                                        x2: 0,
                                        y2: 1,
                                        colorStops: [{
                                            offset: 0, color: '#e0f55a' // 0% 处的颜色
                                        }, {
                                            offset: 1, color: '#639564' // 100% 处的颜色
                                        }],
                                        globalCoord: false // 缺省为 false
                                    }
                                }
                            }

                        },
                        {
                            source: '李四',
                            target: '赖子',
                            value: '',
                            lineStyle: {
                                normal: {
                                    color: {
                                        type: 'linear',
                                        x: 0,
                                        y: 0,
                                        x2: 0,
                                        y2: 1,
                                        colorStops: [{
                                            offset: 0, color: '#e0f55a' // 0% 处的颜色
                                        }, {
                                            offset: 1, color: '#639564' // 100% 处的颜色
                                        }],
                                        globalCoord: false // 缺省为 false
                                    }
                                }
                            }
                        },
                        {
                            source: '李四',
                            target: '王五',
                            value: '',
                            lineStyle: {
                                normal: {
                                    color: {
                                        type: 'linear',
                                        x: 0,
                                        y: 0,
                                        x2: 0,
                                        y2: 1,
                                        colorStops: [{
                                            offset: 0, color: '#df6f30' // 0% 处的颜色
                                        }, {
                                            offset: 1, color: '#915034' // 100% 处的颜色
                                        }],
                                        globalCoord: false // 缺省为 false
                                    }
                                }
                            },
                        },
                        {
                            source: '王五',
                            target: '刘大',
                            value: '',
                            lineStyle: {
                                normal: {
                                    color: {
                                        type: 'linear',
                                        x: 0,
                                        y: 0,
                                        x2: 0,
                                        y2: 1,
                                        colorStops: [{
                                            offset: 0, color: '#eda553' // 0% 处的颜色
                                        }, {
                                            offset: 1, color: '#7c785b' // 100% 处的颜色
                                        }],
                                        globalCoord: false // 缺省为 false
                                    }
                                }
                            },
                        }
                    ],
                    lineStyle: {
                        normal: {
                            opacity: 0.9,
                            width: 5,
                            curveness: 0
                        }
                    },
                    categories: [
                        {name: '人'},
                        {name: '物证'},
                        {name: '不明物体'}
                    ]
                }
            ]
        }
        myChart.setOption(option);
        //客流量统计
        $.get("statistics/passengerStatistics/" + time + "/" + sdate + "/" + udate, function (request) {
            var myChart = echarts.init(document.getElementById('klltj'));
            option = {
                tooltip: {
                    trigger: 'axis',
                    axisPointer: {
                        type: 'shadow'
                    }
                },
                legend: {
                    data: ['男性', '女性'],
                    align: 'right',
                    right: 10,
                    textStyle: {
                        color: "#fff"
                    },
                    itemWidth: 10,
                    itemHeight: 10,
                    itemGap: 35
                },
                grid: {
                    left: '3%',
                    right: '4%',
                    bottom: '3%',
                    containLabel: true
                },
                xAxis: [{
                    type: 'category',
                    data: request.province,
                    axisLine: {
                        show: true,
                        lineStyle: {
                            color: "#063374",
                            width: 1,
                            type: "solid"
                        }
                    },
                    axisTick: {
                        show: false,
                    },
                    axisLabel: {
                        show: true,
                        textStyle: {
                            color: "#00c7ff",
                        }
                    },
                }],
                yAxis: [{
                    type: 'value',
                    axisLabel: {
                        formatter: '{value}'
                    },
                    axisTick: {
                        show: false,
                    },
                    axisLine: {
                        show: false,
                        lineStyle: {
                            color: "#00c7ff",
                            width: 1,
                            type: "solid"
                        },
                    },
                    splitLine: {
                        lineStyle: {
                            color: "#063374",
                        }
                    }
                }],
                series: [{
                    name: '男性',
                    type: 'bar',
                    data: request.man,
                    barWidth: 10, //柱子宽度
                    barGap: 1, //柱子之间间距
                    itemStyle: {
                        normal: {
                            color: new echarts.graphic.LinearGradient(0, 0, 0, 1, [{
                                offset: 0,
                                color: '#008cff'
                            }, {
                                offset: 1,
                                color: '#005193'
                            }]),
                            opacity: 1,
                        }
                    }
                }, {
                    name: '女性',
                    type: 'bar',
                    data: request.woman,
                    barWidth: 10,
                    barGap: 1,
                    itemStyle: {
                        normal: {
                            color: new echarts.graphic.LinearGradient(0, 0, 0, 1, [{
                                offset: 0,
                                color: '#00da9c'
                            }, {
                                offset: 1,
                                color: '#007a55'
                            }]),
                            opacity: 1,
                        }
                    }
                }
                    /*, {
                     name: '完好率',
                     type: 'bar',
                     data: [47, 50, 72, 96, 86],
                     barWidth: 10,
                     barGap: 1,
                     itemStyle: {
                     normal: {
                     color: new echarts.graphic.LinearGradient(0, 0, 0, 1, [{
                     offset: 0,
                     color: '#c4e300'
                     }, {
                     offset: 1,
                     color: '#728400'
                     }]),
                     opacity: 1,
                     }
                     }
                     }*/]
            };
            myChart.setOption(option);
        });

    }
    function findByTime(){
        var sdate=$("#sdate").val();
        var udate=$("#udate").val();
        //评价展示
//            $.get("/statistics/findAppraiseList/"+time, function (request) {
//                console.log(request);
//                var html ="";
//                $.each(request,function (index,item) {
//                    html +="<ul class='ultext'> <li class='li1'> "+item.name+"</li> <li class='li2'>"+item.star+"</li> <li class='li3'>"+item.content+"</li> </ul>";
//                })
//                $("#appraise").empty();
//                $("#appraise").append(html);
//            });
//            $('html').load(/*[[@{/screen}]]*/"./static/static.html")
        //当前客流总量
        $.get("statistics/current/" + time + "/" + sdate + "/" + udate, function (request) {
            $("#null").empty()
            $("#null").append("<div style=\"color: #22d1e4;font-size: 2vw\">" + request + "</div>")
        });
        //年龄占比
        $.get("statistics/age/" + time + "/" + sdate + "/" + udate, function (request) {
            var sum = 0;
            for(var i=0;i<request.length;i++){
                sum += request[i];
            }
            var myChart = echarts.init(document.getElementById('nlzb'));
            option = {
                xAxis: {
                    data: ['0~10', '10~20', '20~30', '30~40', '40~50', '50~60', '60~70', '70~80', '80~90', '90~100'],
                    axisLine: {
                        lineStyle: {
                            color: '#0177d4'
                        }
                    },
                    axisLabel: {
                        color: '#fff',
                        fontSize: 14
                    }
                },
                yAxis: {
                    name: "（人）",
                    nameTextStyle: {
                        color: '#fff',
                        fontSize: 16
                    },
                    axisLine: {
                        lineStyle: {
                            color: '#0177d4'
                        }
                    },
                    axisLabel: {
                        color: '#fff',
                        fontSize: 16
                    },
                    splitLine: {
                        show: false,
                        lineStyle: {
                            color: '#0177d4'
                        }
                    },
                    interval: Math.round(sum/10),
                    max: sum
                },
                series: [{
                    type: 'bar',
                    barWidth: 18,
                    itemStyle: {
                        normal: {
                            color: new echarts.graphic.LinearGradient(0, 0, 0, 1, [{
                                offset: 0,
                                color: '#00b0ff'
                            }, {
                                offset: 0.8,
                                color: '#7052f4'
                            }], false)
                        }
                    },
                    data: request
                }]
            };
            myChart.setOption(option);
        });
        //性别占比
        $.get("statistics/sex/" + time + "/" + sdate + "/" + udate, function (request) {
            var count = request.manCount+request.womanCount;
            var woman = request.womanCount/count;
            var man = request.manCount/count;
            var womanCount = [woman,0.5,0.4,0.3]
            var manCount = [man,0.5,0.4,0.3]

            var myChart = echarts.init(document.getElementById('nan'));
            option = {
                series: [{
                    type: 'liquidFill',
                    data: manCount,
                    radius: '80%'
                }]
            };
            myChart.setOption(option);
            var myChart = echarts.init(document.getElementById('nv'));
            option = {
                series: [{
                    type: 'liquidFill',
                    data: womanCount,
                    radius: '80%'

                }]
            };
            myChart.setOption(option);
        })
        //各省参观人数
        $.get("statistics/province/" + time + "/" + sdate + "/" + udate, function (request) {
            var province = [];
            $(request).each(function (x, y) {
                province.push({name:y.regionName,value:y.count})
            })

            var myChart = echarts.init(document.getElementById('main'));

            var data = [
                {name: '海门', value: 9},
                {name: '鄂尔多斯', value: 12},
                {name: '招远', value: 12},
                {name: '舟山', value: 12},
                {name: '齐齐哈尔', value: 14},
                {name: '盐城', value: 15},
                {name: '赤峰', value: 16},
                {name: '青岛', value: 18},
                {name: '乳山', value: 18},
                {name: '金昌', value: 19},
                {name: '泉州', value: 21},
                {name: '南通', value: 23},
                {name: '拉萨', value: 24},
                {name: '云浮', value: 24},
                {name: '上海', value: 25},
                {name: '攀枝花', value: 25},
                {name: '承德', value: 25},
                {name: '汕尾', value: 26},
                {name: '丹东', value: 27},
                {name: '瓦房店', value: 30},
                {name: '延安', value: 38},
                {name: '咸阳', value: 43},
                {name: '南昌', value: 54},
                {name: '柳州', value: 54},
                {name: '三亚', value: 54},
                {name: '泸州', value: 57},
                {name: '克拉玛依', value: 72}
            ];

            var geoCoordMap = {
                '海门': [121.15, 31.89],
                '鄂尔多斯': [109.781327, 39.608266],
                '招远': [120.38, 37.35],
                '舟山': [122.207216, 29.985295],
                '齐齐哈尔': [123.97, 47.33],
                '盐城': [120.13, 33.38],
                '赤峰': [118.87, 42.28],
                '青岛': [120.33, 36.07],
                '乳山': [121.52, 36.89],
                '金昌': [102.188043, 38.520089],
                '泉州': [118.58, 24.93],
                '莱西': [120.53, 36.86],
                '日照': [119.46, 35.42],
                '胶南': [119.97, 35.88],
                '南通': [121.05, 32.08],
                '拉萨': [91.11, 29.97],
                '云浮': [112.02, 22.93],
                '梅州': [116.1, 24.55],
                '文登': [122.05, 37.2],
                '上海': [121.48, 31.22],
                '攀枝花': [101.718637, 26.582347],
                '威海': [122.1, 37.5],
                '承德': [117.93, 40.97],
                '厦门': [118.1, 24.46],
                '汕尾': [115.375279, 22.786211],
                '潮州': [116.63, 23.68],
                '丹东': [124.37, 40.13],
                '太仓': [121.1, 31.45],
                '曲靖': [103.79, 25.51],
                '烟台': [121.39, 37.52],
                '福州': [119.3, 26.08],
                '瓦房店': [121.979603, 39.627114],
                '即墨': [120.45, 36.38],
                '抚顺': [123.97, 41.97],
                '玉溪': [102.52, 24.35],
                '张家口': [114.87, 40.82],
                '阳泉': [113.57, 37.85],
                '莱州': [119.942327, 37.177017],
                '湖州': [120.1, 30.86],
                '汕头': [116.69, 23.39],
                '昆山': [120.95, 31.39],
                '宁波': [121.56, 29.86],
                '湛江': [110.359377, 21.270708],
                '揭阳': [116.35, 23.55],
                '荣成': [122.41, 37.16],
                '连云港': [119.16, 34.59],
                '葫芦岛': [120.836932, 40.711052],
                '常熟': [120.74, 31.64],
                '东莞': [113.75, 23.04],
                '河源': [114.68, 23.73],
                '淮安': [119.15, 33.5],
                '泰州': [119.9, 32.49],
                '南宁': [108.33, 22.84],
                '营口': [122.18, 40.65],
                '惠州': [114.4, 23.09],
                '江阴': [120.26, 31.91],
                '蓬莱': [120.75, 37.8],
                '韶关': [113.62, 24.84],
                '嘉峪关': [98.289152, 39.77313],
                '广州': [113.23, 23.16],
                '延安': [109.47, 36.6],
                '太原': [112.53, 37.87],
                '清远': [113.01, 23.7],
                '中山': [113.38, 22.52],
                '昆明': [102.73, 25.04],
                '寿光': [118.73, 36.86],
                '盘锦': [122.070714, 41.119997],
                '长治': [113.08, 36.18],
                '深圳': [114.07, 22.62],
                '珠海': [113.52, 22.3],
                '宿迁': [118.3, 33.96],
                '咸阳': [108.72, 34.36],
                '铜川': [109.11, 35.09],
                '平度': [119.97, 36.77],
                '佛山': [113.11, 23.05],
                '海口': [110.35, 20.02],
                '江门': [113.06, 22.61],
                '章丘': [117.53, 36.72],
                '肇庆': [112.44, 23.05],
                '大连': [121.62, 38.92],
                '临汾': [111.5, 36.08],
                '吴江': [120.63, 31.16],
                '石嘴山': [106.39, 39.04],
                '沈阳': [123.38, 41.8],
                '苏州': [120.62, 31.32],
                '茂名': [110.88, 21.68],
                '嘉兴': [120.76, 30.77],
                '长春': [125.35, 43.88],
                '胶州': [120.03336, 36.264622],
                '银川': [106.27, 38.47],
                '张家港': [120.555821, 31.875428],
                '三门峡': [111.19, 34.76],
                '锦州': [121.15, 41.13],
                '南昌': [115.89, 28.68],
                '柳州': [109.4, 24.33],
                '三亚': [109.511909, 18.252847],
                '自贡': [104.778442, 29.33903],
                '吉林': [126.57, 43.87],
                '阳江': [111.95, 21.85],
                '泸州': [105.39, 28.91],
                '西宁': [101.74, 36.56],
                '宜宾': [104.56, 29.77],
                '呼和浩特': [111.65, 40.82],
                '成都': [104.06, 30.67],
                '大同': [113.3, 40.12],
                '镇江': [119.44, 32.2],
                '桂林': [110.28, 25.29],
                '张家界': [110.479191, 29.117096],
                '宜兴': [119.82, 31.36],
                '北海': [109.12, 21.49],
                '西安': [108.95, 34.27],
                '金坛': [119.56, 31.74],
                '东营': [118.49, 37.46],
                '牡丹江': [129.58, 44.6],
                '遵义': [106.9, 27.7],
                '绍兴': [120.58, 30.01],
                '扬州': [119.42, 32.39],
                '常州': [119.95, 31.79],
                '潍坊': [119.1, 36.62],
                '重庆': [106.54, 29.59],
                '台州': [121.420757, 28.656386],
                '南京': [118.78, 32.04],
                '滨州': [118.03, 37.36],
                '贵阳': [106.71, 26.57],
                '无锡': [120.29, 31.59],
                '本溪': [123.73, 41.3],
                '克拉玛依': [84.77, 45.59],
                '渭南': [109.5, 34.52],
                '马鞍山': [118.48, 31.56],
                '宝鸡': [107.15, 34.38],
                '焦作': [113.21, 35.24],
                '句容': [119.16, 31.95],
                '北京': [116.46, 39.92],
                '徐州': [117.2, 34.26],
                '衡水': [115.72, 37.72],
                '包头': [110, 40.58],
                '绵阳': [104.73, 31.48],
                '乌鲁木齐': [87.68, 43.77],
                '枣庄': [117.57, 34.86],
                '杭州': [120.19, 30.26],
                '淄博': [118.05, 36.78],
                '鞍山': [122.85, 41.12],
                '溧阳': [119.48, 31.43],
                '库尔勒': [86.06, 41.68],
                '安阳': [114.35, 36.1],
                '开封': [114.35, 34.79],
                '济南': [117, 36.65],
                '德阳': [104.37, 31.13],
                '温州': [120.65, 28.01],
                '九江': [115.97, 29.71],
                '邯郸': [114.47, 36.6],
                '临安': [119.72, 30.23],
                '兰州': [103.73, 36.03],
                '沧州': [116.83, 38.33],
                '临沂': [118.35, 35.05],
                '南充': [106.110698, 30.837793],
                '天津': [117.2, 39.13],
                '富阳': [119.95, 30.07],
                '泰安': [117.13, 36.18],
                '诸暨': [120.23, 29.71],
                '郑州': [113.65, 34.76],
                '哈尔滨': [126.63, 45.75],
                '聊城': [115.97, 36.45],
                '芜湖': [118.38, 31.33],
                '唐山': [118.02, 39.63],
                '平顶山': [113.29, 33.75],
                '邢台': [114.48, 37.05],
                '德州': [116.29, 37.45],
                '济宁': [116.59, 35.38],
                '荆州': [112.239741, 30.335165],
                '宜昌': [111.3, 30.7],
                '义乌': [120.06, 29.32],
                '丽水': [119.92, 28.45],
                '洛阳': [112.44, 34.7],
                '秦皇岛': [119.57, 39.95],
                '株洲': [113.16, 27.83],
                '石家庄': [114.48, 38.03],
                '莱芜': [117.67, 36.19],
                '常德': [111.69, 29.05],
                '保定': [115.48, 38.85],
                '湘潭': [112.91, 27.87],
                '金华': [119.64, 29.12],
                '岳阳': [113.09, 29.37],
                '长沙': [113, 28.21],
                '衢州': [118.88, 28.97],
                '廊坊': [116.7, 39.53],
                '菏泽': [115.480656, 35.23375],
                '合肥': [117.27, 31.86],
                '武汉': [114.31, 30.52],
                '大庆': [125.03, 46.58]
            };

            function convertData(data) {
                var res = [];
                for (var i = 0; i < data.length; i++) {
                    var geoCoord = geoCoordMap[data[i].name];
                    if (geoCoord) {
                        res.push({
                            name: data[i].name,
                            value: geoCoord.concat(data[i].value)
                        });
                    }
                }
                return res;
            };

            function randomValue() {
                return Math.round(Math.random() * 1000);
            }


            option = {
                tooltip: {},
                visualMap: {
                    min: 0,
                    max: 1500,
                    left: 'left',
                    top: 'bottom',
                    text: ['高', '低'],
                    seriesIndex: [1],
                    inRange: {
                        color: ['#e0ffff', '#006edd']
                    },
                    textStyle: {
                        color: '#006edd'
                    },
                    calculable: true
                },
                geo: {
                    map: 'china',
                    roam: true,
                    label: {
                        normal: {
                            show: false,
                            textStyle: {
                                color: 'rgba(0,0,0,0.4)'
                            }
                        }
                    },
                    itemStyle: {
                        normal: {
                            borderColor: 'rgba(0, 0, 0, 0.2)'
                        },
                        emphasis: {
                            areaColor: null,
                            shadowOffsetX: 0,
                            shadowOffsetY: 0,
                            shadowBlur: 20,
                            borderWidth: 0,
                            shadowColor: 'rgba(0, 0, 0, 0.5)'
                        }
                    }
                },
                series: [
                    {
                        type: 'scatter',
                        coordinateSystem: 'geo',
                        data: convertData(data),
                        symbolSize: 0,

                        symbol: 'image://imgs/pe.png',
//                symbol: '23',
//

                        symbolRotate: 25,
                        label: {
                            normal: {
                                formatter: '{b}',
                                position: 'right',
                                show: false
                            },
                            emphasis: {
                                show: true
                            }
                        },
                        itemStyle: {
                            normal: {
//                        color: '#F06C00'
                            }
                        }
                    },
                    {
                        name: '',
                        type: 'map',
                        geoIndex: 0,
                        // tooltip: {show: false},
                        data:province

                    }
                ]
            };
            myChart.setOption(option);
        })
        //客流量分析
        $.get("statistics/futureOneMonth/" + time + "/" + sdate + "/" + udate, function (request) {
            var myChart = echarts.init(document.getElementById('kllfx'));
            option = {
                tooltip: {
                    trigger: 'axis',
                    axisPointer: {
                        lineStyle: {
                            color: '#57617B'
                        }
                    }
                },
                legend: {
                    icon: 'rect',
                    itemWidth: 14,
                    itemHeight: 5,
                    itemGap: 13,
                    data: ['增长数'],
                    right: '4%',
                    textStyle: {
                        fontSize: 12,
                        color: '#F1F1F3'
                    }
                },
                grid: {
                    left: '3%',
                    right: '4%',
                    bottom: '3%',
                    containLabel: true
                },
                xAxis: [{
                    type: 'category',
                    boundaryGap: false,
                    axisLine: {
                        lineStyle: {
                            color: '#00c7ff'
                        }
                    },
                    data: ['未来第一月', '未来第二月', '未来第三月', '未来第四月', '未来第五月', '未来第六月']
                }],
                yAxis: [{
                    type: 'value',
                    axisTick: {
                        show: false
                    },
                    axisLine: {
                        lineStyle: {
                            color: '#00c7ff'
                        }
                    },
                    axisLabel: {
                        margin: 10,
                        textStyle: {
                            fontSize: 14
                        }
                    },
                    splitLine: {
                        show: false
                    }
                }],
                series: [{
                    name: '增长数',
                    type: 'line',
                    smooth: true,
                    symbol: 'circle',
                    symbolSize: 5,
                    showSymbol: false,
                    lineStyle: {
                        normal: {
                            width: 1
                        }
                    },
                    areaStyle: {
                        normal: {
                            color: new echarts.graphic.LinearGradient(0, 0, 0, 1, [{
                                offset: 0,
                                color: '#5ff6e9'
                            }, {
                                offset: 0.8,
                                color: '#7370fd'
                            }], false),
                            shadowColor: 'rgba(0, 0, 0, 0.1)',
                            shadowBlur: 10
                        }
                    },
                    itemStyle: {
                        normal: {
                            color: 'rgb(137,189,27)',
                            borderColor: 'rgba(137,189,2,0.27)',
                            borderWidth: 12

                        }
                    },
                    data: request
                }]
            };
            myChart.setOption(option);
        })
        //词云展示
        var myChart = echarts.init(document.getElementById('cyzss'));
        option = {
            title: {
                text: ''
            },
            tooltip: {},
            animationDurationUpdate: 1500,
            animationEasingUpdate: 'quinticInOut',
            color: ['#83e0ff', '#45f5ce', '#b158ff'],
            legend: {
                show: true,
                data: [
                    {name: '', textStyle: {color: '#fff'}},
                    {name: '', textStyle: {color: '#fff'}},
                    {name: '', textStyle: {color: '#fff'}}
                ]
            },
            series: [
                {
                    type: 'graph',
                    layout: 'force',
                    force: {
                        repulsion: 1000,
                        edgeLength: 50
                    },
                    symbolSize: 50,
                    roam: true,
                    label: {
                        normal: {
                            show: true
                        }
                    },
                    edgeSymbolSize: [4, 10],
                    edgeLabel: {
                        normal: {
                            show: true,
                            textStyle: {
                                fontSize: 13
                            },
                            formatter: "{c}"
                        }
                    },

                    data: [
                        {
                            name: '说明',

                            symbolSize: 100,
                            draggable: true,
                            category: 1,
                            itemStyle: {
                                normal: {
                                    borderColor: '#04f2a7',
                                    borderWidth: 6,
                                    shadowBlur: 20,
                                    shadowColor: '#04f2a7',
                                    color: '#001c43',
                                }
                            }
                        },
                        {
                            name: '刀',
                            symbolSize: 70,
                            itemStyle: {
                                normal: {
                                    borderColor: '#04f2a7',
                                    borderWidth: 4,
                                    shadowBlur: 10,
                                    shadowColor: '#04f2a7',
                                    color: '#001c43',
                                }
                            },
                            category: 1,

                        },
                        {
                            name: '指纹',
                            symbolSize: 70,
                            category: 1,
                            itemStyle: {
                                normal: {
                                    borderColor: '#04f2a7',
                                    borderWidth: 4,
                                    shadowBlur: 10,
                                    shadowColor: '#04f2a7',
                                    color: '#001c43',
                                }
                            },

                        },
                        {
                            name: '张三',
                            symbolSize: 70,
                            category: 0,
                            itemStyle: {
                                normal: {
                                    borderColor: '#82dffe',
                                    borderWidth: 4,
                                    shadowBlur: 10,
                                    shadowColor: '#04f2a7',
                                    color: '#001c43',
                                }
                            },

                        },
                        {
                            name: '李四',
                            symbolSize: 70,
                            category: 0,
                            itemStyle: {
                                normal: {
                                    borderColor: '#82dffe',
                                    borderWidth: 4,
                                    shadowBlur: 10,
                                    shadowColor: '#04f2a7',
                                    color: '#001c43',
                                }
                            },

                        },
                        {
                            name: '张三2',
                            category: 0,
                            itemStyle: {
                                normal: {
                                    borderColor: '#82dffe',
                                    borderWidth: 4,
                                    shadowBlur: 10,
                                    shadowColor: '#04f2a7',
                                    color: '#001c43',
                                }
                            },

                        },
                        {
                            name: '无名尸',
                            category: 2,
                            itemStyle: {
                                normal: {
                                    borderColor: '#b457ff',
                                    borderWidth: 4,
                                    shadowBlur: 10,
                                    shadowColor: '#b457ff',
                                    color: '#001c43'
                                }
                            },

                        },
                        {
                            name: '赖子',
                            itemStyle: {
                                normal: {
                                    borderColor: '#82dffe',
                                    borderWidth: 4,
                                    shadowBlur: 10,
                                    shadowColor: '#04f2a7',
                                    color: '#001c43'

                                }
                            },
                            category: 0,

                        },
                        {
                            name: '王五',
                            itemStyle: {
                                normal: {
                                    borderColor: '#82dffe',
                                    borderWidth: 4,
                                    shadowBlur: 10,
                                    shadowColor: '#04f2a7',
                                    color: '#001c43'
                                }
                            },
                            category: 0,

                        },
                        {
                            name: '刘大',
                            category: 0,
                            itemStyle: {
                                normal: {
                                    borderColor: '#82dffe',
                                    borderWidth: 4,
                                    shadowBlur: 10,
                                    shadowColor: '#04f2a7',
                                    color: '#001c43'
                                }
                            },

                        }],
                    links: [
                        {
                            source: '说明',
                            target: '刀',
                            value: '',
                            lineStyle: {
                                normal: {
                                    color: {
                                        type: 'linear',
                                        x: 0,
                                        y: 0,
                                        x2: 0,
                                        y2: 1,
                                        colorStops: [{
                                            offset: 0, color: '#e0f55a' // 0% 处的颜色
                                        }, {
                                            offset: 1, color: '#639564' // 100% 处的颜色
                                        }],
                                        globalCoord: false // 缺省为 false
                                    }
                                }
                            }

                        },
                        {
                            source: '说明',
                            target: '指纹',
                            value: '',
                            lineStyle: {
                                normal: {
                                    color: {
                                        type: 'linear',
                                        x: 0,
                                        y: 0,
                                        x2: 0,
                                        y2: 1,
                                        colorStops: [{
                                            offset: 0, color: '#eda553' // 0% 处的颜色
                                        }, {
                                            offset: 1, color: '#7c785b' // 100% 处的颜色
                                        }],
                                        globalCoord: false // 缺省为 false
                                    }
                                }
                            },
                        },
                        {
                            source: '说明',
                            target: '张三',
                            value: '',
                            lineStyle: {
                                normal: {
                                    color: {
                                        type: 'linear',
                                        x: 0,
                                        y: 0,
                                        x2: 0,
                                        y2: 1,
                                        colorStops: [{
                                            offset: 0, color: '#eda553' // 0% 处的颜色
                                        }, {
                                            offset: 1, color: '#7c785b' // 100% 处的颜色
                                        }],
                                        globalCoord: false // 缺省为 false
                                    }
                                }
                            },
                        },
                        {
                            source: '说明',
                            target: '李四',
                            value: '',
                            lineStyle: {
                                normal: {
                                    color: {
                                        type: 'linear',
                                        x: 0,
                                        y: 0,
                                        x2: 0,
                                        y2: 1,
                                        colorStops: [{
                                            offset: 0, color: '#e0f55a' // 0% 处的颜色
                                        }, {
                                            offset: 1, color: '#639564' // 100% 处的颜色
                                        }],
                                        globalCoord: false // 缺省为 false
                                    }
                                }
                            }
                        },
                        {
                            source: '说明',
                            target: '张三'
                        },
                        {
                            source: '刀',
                            target: '张三2',
                            value: '',
                            lineStyle: {
                                normal: {
                                    color: {
                                        type: 'linear',
                                        x: 0,
                                        y: 0,
                                        x2: 0,
                                        y2: 1,
                                        colorStops: [{
                                            offset: 0, color: '#e0f55a' // 0% 处的颜色
                                        }, {
                                            offset: 1, color: '#639564' // 100% 处的颜色
                                        }],
                                        globalCoord: false // 缺省为 false
                                    }
                                }
                            }
                        },
                        {
                            source: '刀',
                            target: '无名尸', value: '',
                            lineStyle: {
                                normal: {
                                    color: {
                                        type: 'linear',
                                        x: 0,
                                        y: 0,
                                        x2: 0,
                                        y2: 1,
                                        colorStops: [{
                                            offset: 0, color: '#e0f55a' // 0% 处的颜色
                                        }, {
                                            offset: 1, color: '#639564' // 100% 处的颜色
                                        }],
                                        globalCoord: false // 缺省为 false
                                    }
                                }
                            }

                        },
                        {
                            source: '李四',
                            target: '赖子',
                            value: '',
                            lineStyle: {
                                normal: {
                                    color: {
                                        type: 'linear',
                                        x: 0,
                                        y: 0,
                                        x2: 0,
                                        y2: 1,
                                        colorStops: [{
                                            offset: 0, color: '#e0f55a' // 0% 处的颜色
                                        }, {
                                            offset: 1, color: '#639564' // 100% 处的颜色
                                        }],
                                        globalCoord: false // 缺省为 false
                                    }
                                }
                            }
                        },
                        {
                            source: '李四',
                            target: '王五',
                            value: '',
                            lineStyle: {
                                normal: {
                                    color: {
                                        type: 'linear',
                                        x: 0,
                                        y: 0,
                                        x2: 0,
                                        y2: 1,
                                        colorStops: [{
                                            offset: 0, color: '#df6f30' // 0% 处的颜色
                                        }, {
                                            offset: 1, color: '#915034' // 100% 处的颜色
                                        }],
                                        globalCoord: false // 缺省为 false
                                    }
                                }
                            },
                        },
                        {
                            source: '王五',
                            target: '刘大',
                            value: '',
                            lineStyle: {
                                normal: {
                                    color: {
                                        type: 'linear',
                                        x: 0,
                                        y: 0,
                                        x2: 0,
                                        y2: 1,
                                        colorStops: [{
                                            offset: 0, color: '#eda553' // 0% 处的颜色
                                        }, {
                                            offset: 1, color: '#7c785b' // 100% 处的颜色
                                        }],
                                        globalCoord: false // 缺省为 false
                                    }
                                }
                            },
                        }
                    ],
                    lineStyle: {
                        normal: {
                            opacity: 0.9,
                            width: 5,
                            curveness: 0
                        }
                    },
                    categories: [
                        {name: '人'},
                        {name: '物证'},
                        {name: '不明物体'}
                    ]
                }
            ]
        }
        myChart.setOption(option);
        //客流量统计
        $.get("statistics/passengerStatistics/" + time + "/" + sdate + "/" + udate, function (request) {
            var myChart = echarts.init(document.getElementById('klltj'));
            option = {
                tooltip: {
                    trigger: 'axis',
                    axisPointer: {
                        type: 'shadow'
                    }
                },
                legend: {
                    data: ['男性', '女性'],
                    align: 'right',
                    right: 10,
                    textStyle: {
                        color: "#fff"
                    },
                    itemWidth: 10,
                    itemHeight: 10,
                    itemGap: 35
                },
                grid: {
                    left: '3%',
                    right: '4%',
                    bottom: '3%',
                    containLabel: true
                },
                xAxis: [{
                    type: 'category',
                    data: request.province,
                    axisLine: {
                        show: true,
                        lineStyle: {
                            color: "#063374",
                            width: 1,
                            type: "solid"
                        }
                    },
                    axisTick: {
                        show: false,
                    },
                    axisLabel: {
                        show: true,
                        textStyle: {
                            color: "#00c7ff",
                        }
                    },
                }],
                yAxis: [{
                    type: 'value',
                    axisLabel: {
                        formatter: '{value}'
                    },
                    axisTick: {
                        show: false,
                    },
                    axisLine: {
                        show: false,
                        lineStyle: {
                            color: "#00c7ff",
                            width: 1,
                            type: "solid"
                        },
                    },
                    splitLine: {
                        lineStyle: {
                            color: "#063374",
                        }
                    }
                }],
                series: [{
                    name: '男性',
                    type: 'bar',
                    data: request.man,
                    barWidth: 10, //柱子宽度
                    barGap: 1, //柱子之间间距
                    itemStyle: {
                        normal: {
                            color: new echarts.graphic.LinearGradient(0, 0, 0, 1, [{
                                offset: 0,
                                color: '#008cff'
                            }, {
                                offset: 1,
                                color: '#005193'
                            }]),
                            opacity: 1,
                        }
                    }
                }, {
                    name: '女性',
                    type: 'bar',
                    data: request.woman,
                    barWidth: 10,
                    barGap: 1,
                    itemStyle: {
                        normal: {
                            color: new echarts.graphic.LinearGradient(0, 0, 0, 1, [{
                                offset: 0,
                                color: '#00da9c'
                            }, {
                                offset: 1,
                                color: '#007a55'
                            }]),
                            opacity: 1,
                        }
                    }
                }
                    /*, {
                     name: '完好率',
                     type: 'bar',
                     data: [47, 50, 72, 96, 86],
                     barWidth: 10,
                     barGap: 1,
                     itemStyle: {
                     normal: {
                     color: new echarts.graphic.LinearGradient(0, 0, 0, 1, [{
                     offset: 0,
                     color: '#c4e300'
                     }, {
                     offset: 1,
                     color: '#728400'
                     }]),
                     opacity: 1,
                     }
                     }
                     }*/]
            };
            myChart.setOption(option);
        });

    }

    /*]]>*/
</script>
</body>
</html>